mirror of
https://github.com/YunoHost-Apps/freshrss_ynh.git
synced 2024-09-03 18:36:33 +02:00
update 'remove' script
This commit is contained in:
parent
093d32f63a
commit
a324de15d3
1 changed files with 12 additions and 4 deletions
|
@ -1,13 +1,21 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Exit on command errors and treat unset variables as an error
|
||||
set -eu
|
||||
|
||||
# Source app helpers
|
||||
. /usr/share/yunohost/helpers
|
||||
|
||||
db_user=freshrss
|
||||
db_name=freshrss
|
||||
root_pwd=$(sudo cat /etc/yunohost/mysql)
|
||||
domain=$(sudo yunohost app setting freshrss domain)
|
||||
domain=$(ynh_app_setting_get freshrss domain)
|
||||
|
||||
ynh_mysql_drop_db $db_name
|
||||
ynh_mysql_drop_user $db_user
|
||||
|
||||
mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"
|
||||
sudo rm -rf /var/www/freshrss
|
||||
sudo rm -rf /etc/cron.d/freshrss
|
||||
sudo rm -f /etc/nginx/conf.d/$domain.d/freshrss.conf
|
||||
|
||||
sudo service nginx reload
|
||||
sudo service nginx reload
|
||||
sudo yunohost app ssowatconf
|
||||
|
|
Loading…
Reference in a new issue