diff options
author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-12-10 16:17:57 -0800 |
---|---|---|
committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-12-10 16:17:57 -0800 |
commit | f7f3bef313d94439eae5a5763fb8b61ec0ad410f (patch) | |
tree | 9deeaaa716d41a118e0bb7e53a31d1f81a99f68b /ext/installfiles/mac | |
parent | d3bcc58074d608639176ce3cd30fa7c5307676b9 (diff) | |
download | infinitytier-f7f3bef313d94439eae5a5763fb8b61ec0ad410f.tar.gz infinitytier-f7f3bef313d94439eae5a5763fb8b61ec0ad410f.zip |
Move some stuff to clean up root.
Diffstat (limited to 'ext/installfiles/mac')
-rwxr-xr-x | ext/installfiles/mac/check_for_updates.sh | 2 | ||||
-rwxr-xr-x | ext/installfiles/mac/uninstall.sh | 38 |
2 files changed, 40 insertions, 0 deletions
diff --git a/ext/installfiles/mac/check_for_updates.sh b/ext/installfiles/mac/check_for_updates.sh new file mode 100755 index 00000000..05a7907c --- /dev/null +++ b/ext/installfiles/mac/check_for_updates.sh @@ -0,0 +1,2 @@ +#!/bin/bash + diff --git a/ext/installfiles/mac/uninstall.sh b/ext/installfiles/mac/uninstall.sh new file mode 100755 index 00000000..4fa26d00 --- /dev/null +++ b/ext/installfiles/mac/uninstall.sh @@ -0,0 +1,38 @@ +#!/bin/bash + +export PATH=/bin:/usr/bin:/sbin:/usr/sbin + +if [ "$UID" -ne 0 ]; then + echo "Must be run as root; try: sudo $0" + exit 1 +fi + +echo + +echo "This will uninstall ZeroTier One, hit CTRL+C to abort." +echo "Waiting 5 seconds..." +sleep 5 + +ztpath="/Library/Application Support/ZeroTier/One" + +echo "Killing any running zerotier-one service..." +killall -TERM zerotier-one >>/dev/null 2>&1 +sleep 3 +killall -KILL zerotier-one >>/dev/null 2>&1 + +echo "Unloading kernel extension..." +kextunload "$ztpath/tap.kext" + +echo "Erasing binary and support files..." +cd $ztpath +rm -rfv zerotier-one *.persist authtoken.secret identity.public *.log *.pid *.kext + +echo "Done." +echo +echo "Your ZeroTier One identity is still preserved in $ztpath" +echo "as identity.secret and can be manually deleted if you wish. Save it if" +echo "you wish to re-use the address of this node, as it cannot be regenerated." + +echo + +exit 0 |