2015-05-24 23:01:16 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
2015-12-02 21:41:55 +01:00
|
|
|
#set -e
|
2015-05-24 23:01:16 +02:00
|
|
|
|
2015-12-25 21:33:56 +01:00
|
|
|
app=ucoin
|
|
|
|
domain=$(sudo yunohost app setting $app domain)
|
|
|
|
port=$(sudo yunohost app setting $app port)
|
|
|
|
|
2015-12-29 13:11:22 +01:00
|
|
|
# Remove uCoin
|
2016-01-01 11:42:20 +01:00
|
|
|
UCOIN_DIR="/home/admin/.ucoin"
|
2015-12-31 15:30:52 +01:00
|
|
|
[ -s "$UCOIN_DIR/ucoin.sh" ] && . "$UCOIN_DIR/ucoin.sh"
|
2016-01-09 16:37:00 +01:00
|
|
|
ucoind stop
|
|
|
|
rm -Rf $UCOIN_DIR
|
2015-12-29 13:11:22 +01:00
|
|
|
rm -Rf /home/admin/.config/ucoin/
|
2015-12-02 21:41:55 +01:00
|
|
|
|
|
|
|
# Remove uCoin service to YunoHost monitoring
|
|
|
|
sudo yunohost service remove ucoin
|
|
|
|
|
2015-12-25 21:33:56 +01:00
|
|
|
# Remove proxy_pass
|
|
|
|
sudo rm -f /etc/nginx/conf.d/$domain.d/$app.conf
|
|
|
|
sudo service nginx reload
|
|
|
|
|
2015-05-24 23:01:16 +02:00
|
|
|
# Close opened port
|
|
|
|
sudo yunohost firewall disallow TCP $port
|