1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gogs_ynh.git synced 2024-09-03 20:36:23 +02:00
gogs_ynh/scripts/remove

41 lines
1.2 KiB
Text
Raw Normal View History

2016-08-15 15:38:50 +02:00
#!/bin/bash
2018-02-08 17:25:54 +01:00
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
2020-10-11 23:51:25 +02:00
#=================================================
source _common.sh
source /usr/share/yunohost/helpers
2018-02-08 17:25:54 +01:00
#=================================================
# STANDARD REMOVE
#=================================================
2020-10-11 23:51:25 +02:00
# REMOVE SERVICE INTEGRATION IN YUNOHOST
#=================================================
2020-12-06 15:23:22 +01:00
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
2020-10-11 23:51:25 +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
# Remove the dedicated systemd config
ynh_remove_systemd_config
2016-08-15 15:38:50 +02:00
# Remove the app-specific logrotate config
ynh_remove_logrotate
2020-12-06 14:50:47 +01:00
# Remove the dedicated NGINX config
ynh_remove_nginx_config
2016-08-15 15:38:50 +02:00
2022-04-10 13:42:21 +02:00
ynh_secure_remove --file="/var/log/$app"
2020-10-11 23:51:25 +02:00
#=================================================
# END OF SCRIPT
#=================================================
2016-08-15 15:38:50 +02:00
2020-10-11 23:51:25 +02:00
ynh_script_progression --message="Removal of $app completed" --last