1
0
mirror of https://github.com/bitwarden/server.git synced 2024-11-28 13:15:12 +01:00

Fix github.ref comparison in build.yml (#3177)

+ Convert to case statement
+ Extend comment
This commit is contained in:
MtnBurrit0 2023-08-10 14:49:39 -06:00 committed by GitHub
parent ceae31e7bf
commit d5a0e97fea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -357,14 +357,18 @@ jobs:
github.ref == 'refs/heads/rc' || github.ref == 'refs/heads/rc' ||
github.ref == 'refs/heads/hotfix-rc' github.ref == 'refs/heads/hotfix-rc'
run: | run: |
# Set proper image based on branch # Set proper setup image based on branch
if [[ "${{ github.ref }}" == "master" ]]; then case "${{ github.ref }}" in
"refs/heads/master")
SETUP_IMAGE="$_AZ_REGISTRY/setup:dev" SETUP_IMAGE="$_AZ_REGISTRY/setup:dev"
elif [[ "${{ github.ref }}" == "rc" ]]; then ;;
"refs/heads/rc")
SETUP_IMAGE="$_AZ_REGISTRY/setup:rc" SETUP_IMAGE="$_AZ_REGISTRY/setup:rc"
elif [[ "${{ github.ref }}" == "hotfix-rc" ]]; then ;;
"refs/heads/hotfix-rc")
SETUP_IMAGE="$_AZ_REGISTRY/setup:hotfix-rc" SETUP_IMAGE="$_AZ_REGISTRY/setup:hotfix-rc"
fi ;;
esac
STUB_OUTPUT=$(pwd)/docker-stub STUB_OUTPUT=$(pwd)/docker-stub