2016-10-25 00:00:01 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
2017-10-14 14:38:56 +02:00
|
|
|
#=================================================
|
|
|
|
# GENERIC START
|
|
|
|
#=================================================
|
|
|
|
# IMPORT GENERIC HELPERS
|
|
|
|
#=================================================
|
2016-10-25 00:00:01 +02:00
|
|
|
|
2017-10-14 14:38:56 +02:00
|
|
|
source _common.sh
|
|
|
|
source /usr/share/yunohost/helpers
|
2016-10-25 00:00:01 +02:00
|
|
|
|
2017-10-14 14:38:56 +02:00
|
|
|
#=================================================
|
|
|
|
# STANDARD REMOVE
|
|
|
|
#=================================================
|
2020-07-25 23:14:14 +02:00
|
|
|
# REMOVE SERVICE INTEGRATION IN YUNOHOST
|
2017-10-14 14:38:56 +02:00
|
|
|
#=================================================
|
2016-10-25 00:00:01 +02:00
|
|
|
|
2020-12-14 10:34:54 +01:00
|
|
|
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
|
2020-07-25 23:14:14 +02:00
|
|
|
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
|
|
|
then
|
|
|
|
ynh_script_progression --message="Removing $app service integration..." --weight=1
|
|
|
|
yunohost service remove $app
|
|
|
|
fi
|
2016-10-25 00:00:01 +02:00
|
|
|
|
2020-07-25 23:14:14 +02:00
|
|
|
# Remove the dedicated systemd config
|
|
|
|
ynh_remove_systemd_config
|
2016-10-25 00:00:01 +02:00
|
|
|
|
2020-07-25 23:14:14 +02:00
|
|
|
# Remove the dedicated NGINX config
|
2017-10-14 14:38:56 +02:00
|
|
|
ynh_remove_nginx_config
|
|
|
|
|
|
|
|
ynh_remove_logrotate
|
|
|
|
|
2020-07-25 23:14:14 +02:00
|
|
|
ynh_secure_remove --file="/usr/bin/$app"
|
2017-10-14 14:38:56 +02:00
|
|
|
|
2017-11-29 15:42:21 +01:00
|
|
|
ynh_remove_nodejs
|
|
|
|
|
2020-07-25 23:14:14 +02:00
|
|
|
#=================================================
|
|
|
|
# END OF SCRIPT
|
|
|
|
#=================================================
|
|
|
|
|
|
|
|
ynh_script_progression --message="Removal of $app completed" --last
|