Remove old daemon commands
This commit is contained in:
parent
03b065c71d
commit
1163ffd146
|
@ -146,7 +146,7 @@ function restore_local_sip {
|
||||||
exit 3679
|
exit 3679
|
||||||
fi
|
fi
|
||||||
rm -rf $temp_restore_dir
|
rm -rf $temp_restore_dir
|
||||||
service sipwitch restart
|
systemctl restart sipwitch
|
||||||
echo $"Restore of SIP settings complete"
|
echo $"Restore of SIP settings complete"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
@ -212,7 +212,7 @@ function update_sipwitch_daemon {
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
service sipwitch stop
|
systemctl stop sipwitch
|
||||||
|
|
||||||
# remove the original sipwitch daemon if it exists
|
# remove the original sipwitch daemon if it exists
|
||||||
if [ -f /etc/init.d/sipwitch ]; then
|
if [ -f /etc/init.d/sipwitch ]; then
|
||||||
|
|
|
@ -447,7 +447,7 @@ function restore_local_xmpp {
|
||||||
exit 725
|
exit 725
|
||||||
fi
|
fi
|
||||||
rm -rf $temp_restore_dir
|
rm -rf $temp_restore_dir
|
||||||
service prosody restart
|
systemctl restart prosody
|
||||||
chown -R prosody:prosody /var/lib/prosody/*
|
chown -R prosody:prosody /var/lib/prosody/*
|
||||||
echo $"Restore of xmpp settings complete"
|
echo $"Restore of xmpp settings complete"
|
||||||
fi
|
fi
|
||||||
|
@ -472,7 +472,7 @@ function restore_remote_xmpp {
|
||||||
exit 725
|
exit 725
|
||||||
fi
|
fi
|
||||||
rm -rf $temp_restore_dir
|
rm -rf $temp_restore_dir
|
||||||
service prosody restart
|
systemctl restart prosody
|
||||||
chown -R prosody:prosody /var/lib/prosody/*
|
chown -R prosody:prosody /var/lib/prosody/*
|
||||||
echo $"Restore of xmpp settings complete"
|
echo $"Restore of xmpp settings complete"
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -92,7 +92,7 @@ function suspend_site {
|
||||||
fi
|
fi
|
||||||
SUSPENDED_SITE="$1"
|
SUSPENDED_SITE="$1"
|
||||||
nginx_dissite $SUSPENDED_SITE
|
nginx_dissite $SUSPENDED_SITE
|
||||||
service nginx reload
|
systemctl reload nginx
|
||||||
}
|
}
|
||||||
|
|
||||||
function restart_site {
|
function restart_site {
|
||||||
|
@ -101,7 +101,7 @@ function restart_site {
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
nginx_ensite $SUSPENDED_SITE
|
nginx_ensite $SUSPENDED_SITE
|
||||||
service nginx reload
|
systemctl reload nginx
|
||||||
SUSPENDED_SITE=
|
SUSPENDED_SITE=
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -121,7 +121,6 @@ function install_toxcore {
|
||||||
sudo cp /tmp/tox-bootstrapd.conf /etc/tox-bootstrapd.conf
|
sudo cp /tmp/tox-bootstrapd.conf /etc/tox-bootstrapd.conf
|
||||||
rm /tmp/tox-bootstrapd.conf
|
rm /tmp/tox-bootstrapd.conf
|
||||||
|
|
||||||
if [ -f /bin/systemctl ]; then
|
|
||||||
if [ ! -f ~/develop/toxcore/other/bootstrap_daemon/tox-bootstrapd.service ]; then
|
if [ ! -f ~/develop/toxcore/other/bootstrap_daemon/tox-bootstrapd.service ]; then
|
||||||
echo $"File not found ~/develop/toxcore/other/bootstrap_daemon/tox-bootstrapd.service"
|
echo $"File not found ~/develop/toxcore/other/bootstrap_daemon/tox-bootstrapd.service"
|
||||||
exit 7359
|
exit 7359
|
||||||
|
@ -137,12 +136,6 @@ function install_toxcore {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo systemctl restart tox-bootstrapd.service
|
sudo systemctl restart tox-bootstrapd.service
|
||||||
else
|
|
||||||
sudo cp ~/develop/toxcore/other/bootstrap_daemon/tox-bootstrapd.sh /etc/init.d/tox-bootstrapd
|
|
||||||
sudo chmod 755 /etc/init.d/tox-bootstrapd
|
|
||||||
sudo update-rc.d tox-bootstrapd defaults
|
|
||||||
sudo service tox-bootstrapd start
|
|
||||||
fi
|
|
||||||
|
|
||||||
TOX_PUBLIC_KEY=$(cat /var/log/syslog | grep tox | grep "Public Key" | awk -F ' ' '{print $8}' | tail -1)
|
TOX_PUBLIC_KEY=$(cat /var/log/syslog | grep tox | grep "Public Key" | awk -F ' ' '{print $8}' | tail -1)
|
||||||
if [ ${#TOX_PUBLIC_KEY} -lt 30 ]; then
|
if [ ${#TOX_PUBLIC_KEY} -lt 30 ]; then
|
||||||
|
|
|
@ -135,7 +135,7 @@ function renew_startssl {
|
||||||
sed -i "s|$HOSTNAME.crt|$HOSTNAME.bundle.crt|g" /etc/nginx/sites-available/$HOSTNAME
|
sed -i "s|$HOSTNAME.crt|$HOSTNAME.bundle.crt|g" /etc/nginx/sites-available/$HOSTNAME
|
||||||
|
|
||||||
echo $'Certificate installed'
|
echo $'Certificate installed'
|
||||||
service nginx restart
|
systemctl restart nginx
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -205,7 +205,7 @@ function restore_mariadb {
|
||||||
exit 962
|
exit 962
|
||||||
fi
|
fi
|
||||||
echo $"Restarting database"
|
echo $"Restarting database"
|
||||||
service mysql restart
|
systemctl restart mysql
|
||||||
echo $"Change the MariaDB password to the backup version"
|
echo $"Change the MariaDB password to the backup version"
|
||||||
DATABASE_PASSWORD="$db_pass"
|
DATABASE_PASSWORD="$db_pass"
|
||||||
${PROJECT_NAME}-pass -u root -a mariadb -p "$DATABASE_PASSWORD"
|
${PROJECT_NAME}-pass -u root -a mariadb -p "$DATABASE_PASSWORD"
|
||||||
|
|
|
@ -198,7 +198,7 @@ function restore_mariadb {
|
||||||
exit 962
|
exit 962
|
||||||
fi
|
fi
|
||||||
echo $"Restarting database"
|
echo $"Restarting database"
|
||||||
service mysql restart
|
systemctl restart mysql
|
||||||
echo $"Change the MariaDB password to the backup version"
|
echo $"Change the MariaDB password to the backup version"
|
||||||
DATABASE_PASSWORD="$db_pass"
|
DATABASE_PASSWORD="$db_pass"
|
||||||
${PROJECT_NAME}-pass -u root -a mariadb -p "$DATABASE_PASSWORD"
|
${PROJECT_NAME}-pass -u root -a mariadb -p "$DATABASE_PASSWORD"
|
||||||
|
|
|
@ -35,7 +35,7 @@ function suspend_site {
|
||||||
# suspends a given website
|
# suspends a given website
|
||||||
SUSPENDED_SITE="$1"
|
SUSPENDED_SITE="$1"
|
||||||
nginx_dissite $SUSPENDED_SITE
|
nginx_dissite $SUSPENDED_SITE
|
||||||
service nginx reload
|
systemctl reload nginx
|
||||||
}
|
}
|
||||||
|
|
||||||
function restart_site {
|
function restart_site {
|
||||||
|
@ -44,7 +44,7 @@ function restart_site {
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
nginx_ensite $SUSPENDED_SITE
|
nginx_ensite $SUSPENDED_SITE
|
||||||
service nginx reload
|
systemctl reload nginx
|
||||||
SUSPENDED_SITE=
|
SUSPENDED_SITE=
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue