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 | |
if [ -z "$1" ];then | |
echo "Command ?" | |
else | |
COMMAND="$1" | |
omp --host=localhost --port=9390 --username=admin --password=admin $COMMAND | |
fi |
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 | |
cd /opt | |
mkdir sqlite3-databases ; cd sqlite3-databases | |
wget http://www.sqlitetutorial.net/wp-content/uploads/2018/03/chinook.zip | |
unzip chinook.zip ; rm chinook.zip | |
virtualenv venv | |
source venv/bin/activate | |
pip install flask flask-jsonpify flask-sqlalchemy flask-restful | |
pip freeze |
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 | |
curl https://icanhazip.com |
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
echo -e "\nEnter your var :" | |
VAR=$1 | |
if [ -z $VAR ] | |
then | |
clear | |
echo -e "\nvar is empty, try again ..." | |
else | |
echo -e "\nvar is okay, lets do this ..." | |
fi |
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
echo "# my project" >> README.md | |
git init | |
git add * | |
git commit -m 'initial commit' | |
git remote add origin https://github.com/user/project.git | |
git push -u origin master |
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 | |
#apt-get install dsniff cutter | |
echo -e "\nEnter IP you want to block :" | |
VAR=$1 | |
if [ -z $VAR ] | |
then | |
clear | |
echo -e "\Please input IP and try again ..." | |
else | |
echo -e "\nOkay, lets do this ..." |
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 | |
# remote port 9000 | |
# local port to forward 3000 | |
ssh -R 9000:localhost:3000 user@example.com |
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 | |
# Push new dynamic public ip address | |
# to a dyndns server | |
salt-call event.send 'vpnwall/custom/event/updatedyndns' \ | |
"{domainname: $(cat /etc/hostname), newip: $(https://icanhazip.com)}" |
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 | |
today=`date '+%Y_%m_%d__%H_%M_%S'` | |
filename="/home/el/myfile/$today.ponies" | |
echo $filename |
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 | |
#PUT DOMAIN NAMES IN THESES VAR | |
domainnames=("example.com" "example.net") | |
ctrl_c(){ | |
echo -e "quitting ..." | |
exit 130; | |
} |