test_apps/legacy_app_ynh/scripts/remove

20 lines
392 B
Text
Raw Permalink Normal View History

2017-04-28 04:34:16 +02:00
set -eux
# Source app helpers
source /usr/share/yunohost/helpers
# Recover arguments
app=$YNH_APP_INSTANCE_NAME
domain=$(sudo yunohost app setting $app domain)
db_user=$app
ynh_mysql_drop_db $db_user
ynh_mysql_drop_user $db_user
sudo rm -rf /var/www/$app
sudo rm /etc/nginx/conf.d/$domain.d/$app.conf
sudo rm -f /etc/importantfile
sudo service nginx restart
2017-04-28 04:34:16 +02:00
sudo yunohost app ssowatconf