diff --git a/.github/workflows/build_and_deploy.yml b/.github/workflows/build_and_deploy.yml index 3ee4348f58..065084bc06 100644 --- a/.github/workflows/build_and_deploy.yml +++ b/.github/workflows/build_and_deploy.yml @@ -70,6 +70,7 @@ jobs: - name: Vars and Secrets to Env env: GIT_BRANCH: ${{ github.ref_name }} + TAG_OVERRIDE: ${{ needs.backend-build.outputs.image_tag }} VARS_CONTEXT: ${{ toJson(vars) }} SECRETS_CONTEXT: ${{ toJson(secrets) }} run: | @@ -81,6 +82,7 @@ jobs: # Set all vars echo "GIT_BRANCH=${GIT_BRANCH}" >> $GITHUB_ENV + echo "TAG_OVERRIDE=${TAG_OVERRIDE}" >> $GITHUB_ENV echo "${VARS_CONTEXT}" | to_envs >> $GITHUB_ENV echo "${SECRETS_CONTEXT}" | to_envs >> $GITHUB_ENV @@ -94,11 +96,12 @@ jobs: echo "Substituing variables from .env.example --> .env" ./envsubst < .env.example > .env echo "GIT_BRANCH=${GIT_BRANCH}" >> .env + echo "TAG_OVERRIDE=${TAG_OVERRIDE}" >> .env - name: Backend smoke test run: | # Migrate db first, so api works - docker compose up -d migrations + docker compose up migrations --exit-code-from migrations # Run without migrations (give exit code 0) docker compose up -d \