2014-12-30 17:33:21 +01:00

18 lines
489 B
Bash

#!/bin/bash
db_user=ffsync
db_name=ffsync
root_pwd=$(sudo cat /etc/yunohost/mysql)
domain=$(sudo yunohost app setting ffsync domain)
mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"
sudo rm -rf /opt/yunohost/ffsync
sudo rm -f /etc/nginx/conf.d/$domain.d/ffsync.conf
sudo rm -f /etc/uwsgi/apps-enabled/ffsync.ini
sudo rm -f /etc/uwsgi/apps-available/ffsync.ini
sudo service uwsgi stop
sudo killall uwsgi
sudo service uwsgi start
sudo userdel ffsync