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/sh | |
while true; do | |
errorstr="$(ping -c1 -n -w1 8.8.8.8 2>&1 | grep '100% packet loss')" | |
if [ "$errorstr" != '' ]; then | |
echo -n 'reconnecting... ' | |
./uni_reauth.sh | |
else | |
echo 'still ok' | |
fi | |
sleep 1 |
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
dependencies: | |
post: | |
- export DEBIAN_FRONTEND=noninteractive | |
- sudo apt-get -y remove mysql-server | |
- sudo apt-get -y autoremove | |
- sudo apt-get -y install software-properties-common | |
- sudo add-apt-repository -y ppa:ondrej/mysql-5.6 | |
- sudo apt-get update | |
- sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password ""' | |
- sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password ""' |