1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/shellinabox_ynh.git synced 2024-09-03 20:26:12 +02:00
shellinabox_ynh/scripts/remove
2015-05-08 12:13:03 +02:00

22 lines
590 B
Bash

#!/bin/bash
set -e
# Retrieve arguments
domain=$(sudo yunohost app setting shellinabox domain)
path=$(sudo yunohost app setting shellinabox path)
# Stop and remove shellinabox
sudo service shellinabox stop || echo "ShellInABox already stopped"
sudo apt-get remove --purge -y -qq shellinabox || echo "ShellInABox already uninstalled"
# Remove Shell In A Box configuration
sudo rm -f /etc/default/shellinabox
# Remove service
sudo yunohost service remove shellinabox
# Remove Nginx proxy configuration
sudo rm -f /etc/nginx/conf.d/$domain.d/shellinabox.conf
sudo service nginx reload