Skip to content

Commit

Permalink
Add build target
Browse files Browse the repository at this point in the history
  • Loading branch information
cjcolvar authored Aug 14, 2023
1 parent 030ae63 commit 7e018a4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/podman-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ env:
DOCKERHUB_IMAGE_REGISTRY: docker.io/avalonmediasystem
DOCKERHUB_USER: ${{ secrets.dockerhub_user }}
DOCKERHUB_PASSWORD: ${{ secrets.dockerhub_password }}
IMAGE_TAG: ${{ fromJSON('{"refs/heads/main":"production","refs/heads/develop":"develop","refs/heads/staging":"staging","refs/heads/sandbox":"sandbox"}')[github.ref] }}
IMAGE_TAG: ${{ fromJSON('{"refs/heads/main":"production","refs/heads/develop":"develop","refs/heads/staging":"staging","refs/heads/sandbox":"sandbox","refs/heads/cjcolvar-patch-4":"develop"}')[github.ref] }}
BRANCH: ${{ fromJSON('{"refs/heads/main":"main","refs/heads/develop":"develop","refs/heads/staging":"staging","refs/heads/sandbox":"sandbox","refs/heads/cjcolvar-patch-4":"develop"}')[github.ref] }}
BUILD_TARGET: ${{ fromJSON('{"refs/heads/main":"prod","refs/heads/develop":"dev","refs/heads/staging":"prod","refs/heads/sandbox":"prod","refs/heads/cjcolvar-patch-4":"dev"}')[github.ref] }}

jobs:

Expand All @@ -30,6 +31,7 @@ jobs:
tags: ${{ env.IMAGE_TAG }} ${{ github.sha }}
containerfiles: ./Dockerfile
oci: true
extra-args: --target ${{ env.BUILD_TARGET }}
- name: Push To GHCR
uses: redhat-actions/push-to-registry@v2
with:
Expand Down

0 comments on commit 7e018a4

Please sign in to comment.