#!/bin/bash
source _common.sh
source /usr/share/yunohost/helpers

ynh_script_progression "Arrêt et suppression du service..."
yunohost service remove "$app"
ynh_systemctl --action="stop" --service="$app"
ynh_config_remove_systemd

ynh_script_progression "Suppression de la configuration nginx..."
ynh_config_remove_nginx

ynh_script_progression "Suppression des règles sudo..."
ynh_safe_rm "/etc/sudoers.d/$app"

ynh_script_progression "Désinstallation terminée !"
