Skip to content

Commit

Permalink
setup unintall for systemd and no restartd
Browse files Browse the repository at this point in the history
  • Loading branch information
jwcooper committed Mar 6, 2018
1 parent ffac7e8 commit 8847751
Showing 1 changed file with 8 additions and 14 deletions.
22 changes: 8 additions & 14 deletions scripts/uninstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@ WEBIDE_ROOT="/usr/share/adafruit"
WEBIDE_HOME="/home/webide"
NODE_PATH=""

echo "**** Removing restartd WebIDE configuration ****"
sed -i '/adafruit-webide.sh/ d' /etc/restartd.conf
#kill all restartd processes, and restart one
pkill -f restartd || true
sleep 5s
restartd

echo "**** Removing webide user from sudoers ****"
if [ -f "/etc/sudoers.tmp" ]; then
rm /etc/sudoers.tmp
Expand All @@ -30,21 +23,22 @@ echo "**** Stopping the Adafruit WebIDE ****"
service adafruit-webide.sh stop
sleep 5s

echo "**** Removing update-rc.d service ****"
update-rc.d -f adafruit-webide.sh remove
rm /etc/init.d/adafruit-webide.sh
echo "**** Removing systemd service ****"
systemctl stop adafruit-webide
systemctl disable adafruit-webide
rm /etc/systemd/system/adafruit-webide.service
systemctl daemon-reload
systemctl reset-failed

echo "**** Removing the WebIDE Folder ****"
rm -rf "$WEBIDE_ROOT"
echo "**** Removing webide user ****"
userdel -r webide

echo "**** Removing redis server setting ****"
redis-cli del server

echo "**** The Adafruit WebIDE is now uninstalled! ****"
echo "**** During the installation process, there were a few ****"
echo "**** libraries installed that we did not uninstall as ****"
echo "**** we're not able to determine if other applications are dependent ****"
echo "**** on them. If you are not using them, you can uninstall by executing ****"
echo "**** the following command: ****"
echo "**** sudo apt-get remove nodejs npm redis-server git restartd libcap2-bin avahi-daemon i2c-tools python-smbus ****"
echo "**** sudo apt-get remove nodejs-legacy yarn git libcap2-bin i2c-tools python-smbus ntp libkrb5-dev ****"

0 comments on commit 8847751

Please sign in to comment.