Add refresh.sh exec on compass-core 15/25015/1
authorQiLiang <liangqi1@huawei.com>
Mon, 28 Nov 2016 14:56:44 +0000 (22:56 +0800)
committerQiLiang <liangqi1@huawei.com>
Mon, 28 Nov 2016 14:56:44 +0000 (22:56 +0800)
Add refresh.sh exec on compass-core, so user don't need to manually execute
the refresh.sh script when they what redeploy the openstack without redeploy
the compass-core vm.

Change-Id: I63803ee1db1caafdb71f8ead44f04c62c0ad0f98
Signed-off-by: QiLiang <liangqi1@huawei.com>
deploy/compass_vm.sh
deploy/launch.sh

index 63c1998..a83f2b0 100755 (executable)
@@ -71,6 +71,11 @@ function inject_compass_conf() {
     _inject_dashboard_conf
 }
 
+function refresh_compass_core () {
+    cmd="/opt/compass/bin/refresh.sh"
+    exec_cmd_on_compass $cmd
+}
+
 function wait_ok() {
     set +x
     log_info "wait_compass_ok enter"
index 348d11e..80e7853 100755 (executable)
@@ -62,6 +62,8 @@ if [[ "$DEPLOY_COMPASS" == "true" ]]; then
         log_error "launch_compass failed"
         exit 1
     fi
+else
+    refresh_compass_core
 fi
 
 if [[ -z "$REDEPLOY_HOST" || "$REDEPLOY_HOST" == "false" ]]; then