File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -114,13 +114,15 @@ jobs:
114114 continue-on-error : false
115115 run : |
116116 PR_NUM_TAG=$(echo "${GITHUB_REF}" | sed 's/refs\/pull\/\([0-9]*\)\/merge/\1/')
117-
117+ SHORT_COMMIT_HASH=$(git rev-parse --short ${GITHUB_SHA})
118118
119119 docker build -f Dockerfile.dotnet.base -t cohort-manager-dotnet-base:latest .
120120 docker tag cohort-manager-dotnet-base:latest "ghcr.io/nhsdigital/cohort-manager-dotnet-base:${PR_NUM_TAG}"
121+ docker tag cohort-manager-dotnet-base:latest "ghcr.io/nhsdigital/cohort-manager-dotnet-base:${SHORT_COMMIT_HASH}"
122+
121123 docker build -f Dockerfile.function.base -t cohort-manager-function-base:latest .
122124 docker tag cohort-manager-function-base:latest "ghcr.io/nhsdigital/cohort-manager-function-base:${PR_NUM_TAG}"
123- SHORT_COMMIT_HASH=$(git rev-parse --short ${GITHUB_SHA})
125+ docker tag cohort-manager-function-base:latest "ghcr.io/nhsdigital/cohort-manager-function-base:${SHORT_COMMIT_HASH}"
124126
125127 docker push "ghcr.io/nhsdigital/cohort-manager-dotnet-base:${PR_NUM_TAG}"
126128 docker push "ghcr.io/nhsdigital/cohort-manager-dotnet-base:${SHORT_COMMIT_HASH}"
You can’t perform that action at this time.
0 commit comments