Merge "Handle "updating" and "recovering" app update states during upgrade activation"

This commit is contained in:
Zuul 2021-04-22 21:45:54 +00:00 committed by Gerrit Code Review
commit 416c209cde
1 changed files with 6 additions and 2 deletions

View File

@ -101,8 +101,12 @@ if [ "$FROM_RELEASE" == "20.06" ] && [ "$ACTION" == "activate" ]; then
log "$NAME: $EXISTING_APP_NAME, version $EXISTING_APP_VERSION, is currently in the state: $EXISTING_APP_STATUS" log "$NAME: $EXISTING_APP_NAME, version $EXISTING_APP_VERSION, is currently in the state: $EXISTING_APP_STATUS"
if [ "x${UPGRADE_APP_VERSION}" == "x${EXISTING_APP_VERSION}" ]; then if [ "x${UPGRADE_APP_VERSION}" == "x${EXISTING_APP_VERSION}" ]; then
log "$NAME: ${UPGRADE_APP_NAME}, version ${EXISTING_APP_VERSION}, is already present. skipping..." # If the app is in uploaded or applied state, then we continue with next iteration.
continue # Else, the code execution proceeds and the script would exit with an unexpected state.
if [[ "${EXISTING_APP_STATUS}" =~ ^(uploaded|applied)$ ]]; then
log "$NAME: ${UPGRADE_APP_NAME}, version ${EXISTING_APP_VERSION}, is already present. skipping..."
continue
fi
fi fi
# All applications should be in an 'applied' or 'uploaded' state. Any other state is unexpected # All applications should be in an 'applied' or 'uploaded' state. Any other state is unexpected