Linux install and uninstall seem to work.

This commit is contained in:
Adam Ierymenko 2013-11-08 17:37:47 -05:00
commit 165bc589fd
7 changed files with 28 additions and 15 deletions

View file

@ -56,7 +56,7 @@ fi
case "$1" in
start)
if [ $running -eq 0 ]; then
if [ $running -gt 0 ]; then
echo "ZeroTier One already running."
exit 0
fi

View file

@ -9,7 +9,7 @@ fi
echo
echo "Going to uninstall zerotier-one, hit CTRL+C to abort."
echo "This will uninstall ZeroTier One, hit CTRL+C to abort."
echo "Waiting 5 seconds..."
sleep 5
@ -18,15 +18,18 @@ killall -q -TERM zerotier-one
sleep 2
killall -q -KILL zerotier-one
echo "Erasing binary and support files..."
cd /var/lib/zerotier-one
rm -fv zerotier-one *.persist authtoken.secret identity.public *.log
rm -rfv updates.d networks.d iddb.d
echo "Removing init items..."
echo "Removing SysV init items..."
rm -fv /etc/init.d/zerotier-one
find /etc/rc*.d -name '???zerotier-one' -print0 | xargs -0 rm -fv
echo "Erasing binary and support files..."
cd /var/lib/zerotier-one
rm -fv zerotier-one *.persist authtoken.secret identity.public *.log *.pid
rm -rfv updates.d networks.d iddb.d
echo "Erasing anything installed into system bin directories..."
rm -fv /usr/local/bin/zerotier-* /usr/bin/zerotier-*
echo "Done."
echo
echo "Your ZeroTier One identity is still preserved in /var/lib/zerotier-one"