1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/emailpoubelle_ynh.git synced 2024-09-03 18:26:29 +02:00
emailpoubelle_ynh/scripts/remove

43 lines
1.3 KiB
Bash

#!/bin/bash
source _common.sh
source /usr/share/yunohost/helpers
#=================================================
# REMOVE NGINX CONFIGURATION
#=================================================
ynh_script_progression "Removing NGINX web server configuration..."
# Remove the dedicated NGINX config
ynh_config_remove_nginx
#=================================================
# REMOVE PHP-FPM CONFIGURATION
#=================================================
ynh_script_progression "Removing PHP-FPM configuration..."
# Remove the dedicated PHP-FPM config
ynh_config_remove_phpfpm
#=================================================
# SPECIFIC REMOVE
#=================================================
# REMOVE VARIOUS FILES
#=================================================
ynh_script_progression "Removing various files..."
# Remove a cron file
ynh_safe_rm "/etc/cron.d/$app"
ynh_replace --match="devnull:/dev/null" --replace="" --file="/etc/aliases"
newaliases
ynh_safe_rm "/usr/share/yunohost/hooks/conf_regen/98-postfix_emailpoubelle"
yunohost tools regen-conf postfix
ynh_systemctl --service=postfix --action=reload
#=================================================
# END OF SCRIPT
#=================================================
ynh_script_progression "Removal of $app completed"