Browse Source

updated start/stop scripts to run form /etc/rc.local (without sudo)

Joseph Snow 8 years ago
parent
commit
5d33f2fb4e
1 changed files with 3 additions and 1 deletions
  1. 3 1
      stop

+ 3 - 1
stop

@@ -3,7 +3,9 @@
 ps waux | grep node | grep -v grep
 
 echo "stopping ..."
-sudo forever stopall
+if [ "$(id -u)" != "0" ]; then
+	sudo forever stopall
+fi
 forever stopall
 
 sleep 3