aboutsummaryrefslogtreecommitdiffstats
path: root/boot/music_vm_init.sh
diff options
context:
space:
mode:
Diffstat (limited to 'boot/music_vm_init.sh')
-rw-r--r--boot/music_vm_init.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/boot/music_vm_init.sh b/boot/music_vm_init.sh
index 372cd33e..2241ed13 100644
--- a/boot/music_vm_init.sh
+++ b/boot/music_vm_init.sh
@@ -14,4 +14,11 @@ docker pull $NEXUS_DOCKER_REPO/onap/music/music:$DOCKER_IMAGE_VERSION
cd /opt/music/distribution/dockermusic
git pull
+
+#Stop existing docker containers (if any)
+if [ $(docker ps | wc -l) > 1 ]; then
+ ./music.sh stop
+ sleep 2
+fi
+
./music.sh start \ No newline at end of file