Browse Source

misc fixes

Tobias Cudnik 2 years ago
parent
commit
3e0fbb4ad7
1 changed files with 4 additions and 3 deletions
  1. 4 3
      scripts/nm-quick.sh

+ 4 - 3
scripts/nm-quick.sh

@@ -2,6 +2,7 @@
 
 
 CONFIG_FILE=netmaker.env
 CONFIG_FILE=netmaker.env
 # location of nm-quick.sh (usually `/root`)
 # location of nm-quick.sh (usually `/root`)
+# TODO use everywhere
 SCRIPT_DIR=$(dirname "$(realpath "$0")")
 SCRIPT_DIR=$(dirname "$(realpath "$0")")
 CONFIG_PATH="$SCRIPT_DIR/$CONFIG_FILE"
 CONFIG_PATH="$SCRIPT_DIR/$CONFIG_FILE"
 LATEST=$(curl -s https://api.github.com/repos/gravitl/netmaker/releases/latest | grep "tag_name" | cut -d : -f 2,3 | tr -d [:space:],\")
 LATEST=$(curl -s https://api.github.com/repos/gravitl/netmaker/releases/latest | grep "tag_name" | cut -d : -f 2,3 | tr -d [:space:],\")
@@ -770,9 +771,9 @@ set -e
 set_install_vars
 set_install_vars
 
 
 # stop
 # stop
-for name in "mq" "netmaker-ui" "coredns" "turn" "caddy" "netmaker"; do
-	if test -n "$(docker ps | grep name)"; then
-		docker stop $name
+for name in "mq" "netmaker-ui" "coredns" "turn" "caddy" "netmaker" "netmaker-exporter" "grafana" "prometheus"; do
+	if test -n "$(docker ps | grep -w name)"; then
+		docker stop "$name"
 	fi
 	fi
 done
 done