This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
build_settings: | |
mysql: | |
host: 'localhost' | |
user: '-----' | |
pass: '-----' | |
setup: | |
mysql: | |
- "DROP DATABASE IF EXISTS -----;" | |
- "CREATE DATABASE -----;" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! | |
* OS.js - JavaScript Cloud/Web Desktop Platform | |
* | |
* Mysql Handler: Login screen and session/settings handling via database | |
* PLEASE NOTE THAT THIS AN EXAMPLE ONLY, AND SHOUD BE MODIFIED BEFORE USAGE | |
* | |
* Copyright (c) 2011-2016, Anders Evenrud <[email protected]> | |
* All rights reserved. | |
* | |
* Redistribution and use in source and binary forms, with or without |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo '#################################' | |
echo '# #' | |
echo '# FAIL2BAN INSTALL #' | |
echo '# #' | |
echo '#################################' | |
echo '' | |
apt-get install fail2ban | |
service fail2ban stop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo '#################################' | |
echo '# #' | |
echo '# FIREWALL CONFIGURATION #' | |
echo '# #' | |
echo '#################################' | |
echo '' | |
cat > /etc/iptables.firewall.rules << EOL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
SAMBATOOL=/usr/local/samba/bin/samba-tool | |
USER=admin | |
PASSWORD="PASSWORD" | |
HOST="DNS-SERV.TEST.LOCAL" | |
DOMAIN |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
For each new VM | |
create virtual mac and add it to physical properties in network-device | |
under E100 | |
then add this lines to /etc/network/interfaces | |
# This file describes the network interfaces available on your system | |
# and how to activate them. For more information, see interfaces(5). | |
source /etc/network/interfaces.d/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
;; VARIABLES GLOBALES ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
breed [capteurs capteur] | |
breed [habitants habitant] | |
breed [batiments batiment] | |
breed [capteursTemperature capteurTemperature] | |
breed [capteursPresence capteurPresence] | |
breed [radiators rad] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function show_status($done, $total, $size = 50) | |
{ | |
static $start_time; | |
// if we go over our bound, just ignore it | |
if ($done > $total) return; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Dump Mongo Dbs database every night using mongodump | |
# Author: by yrushka.com | |
## Binary path ## | |
#MONGO="/usr/bin/mongo" | |
#MONGODUMP="/usr/bin/mongodump" | |
/usr/bin/mongodump --out /var/backup/mongodb/`date +"%Y_%m_%d_%H-%M__dump"` | |
tar -cvf /var/backup/mongodb/`date +"%Y_%m_%d_%H-%M__dump.tar"` /var/backup/mongodb/`date +"%Y_%m_%d_%H-%M__dump"` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#date du jour | |
DATE=`date +%y_%m_%d_%H-%M` | |
mkdir /var/backup/mysql/$DATE | |
#liste des dossier | |
LISTEBDD=$( echo 'show databases' | mysql -uroot -pPASSWORD ) |