Add a hook for teardown to stop installer inf loop 77/18977/1
authorLusheng Ji <lji@research.att.com>
Mon, 16 Oct 2017 02:17:30 +0000 (22:17 -0400)
committerLusheng Ji <lji@research.att.com>
Mon, 16 Oct 2017 02:17:36 +0000 (22:17 -0400)
Issue-Id: DCAEGEN2-127
Change-Id: I7396a17049fb3186203f48f0f57e77ef135c8dff
Signed-off-by: Lusheng Ji <lji@research.att.com>
bootstrap/installer-docker.sh-template
bootstrap/teardown.sh

index 5284837..9900d06 100755 (executable)
@@ -401,7 +401,8 @@ cfy install -p ./blueprints/ph/${PHBP} -b policy_handler_BP -d policy_handler -i
 
 
 # Keep the container up
-while true
+rm -f /tmp/ready_to_exit
+while [ ! -e /tmp/ready_to_exit ]
 do
-    sleep 300
+    sleep 30
 done
index 47508d1..4d1836c 100755 (executable)
@@ -22,6 +22,9 @@
 #
 set -x
 set -e
+
+rm -f /tmp/ready_to_exit
+
 source ./dcaeinstall/bin/activate
 cd ./consul
 cfy status
@@ -37,3 +40,4 @@ cfy uninstall -d consul
 cd ..
 cfy local uninstall
 
+touch /tmp/ready_to_exit