Skip to content

Commit

Permalink
Added command line option to not start service after upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Brehovsky committed Mar 14, 2018
1 parent 025eba3 commit 92be1d2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions bin/avst-app
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ do
FORCE=1
ALLOW_DOWNGRADE=1
;;
--no-autostart)
START_AFTER_UPGRADE=1
;;
--allow-git-avst-keeper)
GIT_AVST_KEEPER=1
;;
Expand Down
4 changes: 3 additions & 1 deletion share/avst-app/lib/common/upgrade.d/99start_service
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ fi
RESULT_SERVICE_STOPPED=$(run_cmd "service '${INSTANCE_NAME}' status | grep '${SERVICE_STATUS_SEARCH_STRING}'")
debug "${RESULT_SERVICE_STOPPED}"
if [[ "$(get_std_return ${RESULT_SERVICE_STOPPED})" == "0" ]]; then
run_cmd start_service
if [[ "${START_AFTER_UPGRADE:-0}" == "0" ]]; then
run_cmd start_service
fi
fi

0 comments on commit 92be1d2

Please sign in to comment.