JIRA: -
Under current deploy procedure, when compass
containers are running, they will not be
recreated during redeploy. Using DEPLOY_FIRST_TIME
to determine to run the container create process
when first time deploy
Change-Id: Ic13fd84ed41afdad29c96f803feff3298cbbcfde
Signed-off-by: Harry Huang <huangxiangyu5@huawei.com>
export machines
CONTAINER_ALIVE=$(check_container_alive)
- if [[ "$DEPLOY_COMPASS" == "true" && "$CONTAINER_ALIVE" == "false" ]]; then
+ if
+ [[ "$DEPLOY_FIRST_TIME" == "true" ]] ||
+ [[ "$DEPLOY_COMPASS" == "true" && "$CONTAINER_ALIVE" == "false" ]]
+ then
if ! prepare_env;then
echo "prepare_env failed"
exit 1
log_error "launch_compass failed"
exit 1
fi
- elif [[ "$DEPLOY_COMPASS" == "true" && "$CONTAINER_ALIVE" == "true" ]]; then
+ elif
+ [[ "$DEPLOY_COMPASS" == "true" && "$CONTAINER_ALIVE" == "true" ]]
+ then
refresh_compass_core
fi
else