Skip to content

Commit

Permalink
Only use first base image tag
Browse files Browse the repository at this point in the history
  • Loading branch information
tmetzl committed Nov 12, 2024
1 parent 6554680 commit 17b9b49
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/build_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,12 @@ jobs:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_SECRET }}
- name: Extract first base image tag
id: extract_base_tag
run: |
IFS=',' read -r -a base_tags <<< "${{ inputs.base_image_tag }}"
first_base_tag="${base_tags[0]}"
echo "first_base_tag=$first_base_tag" >> $GITHUB_OUTPUT
- name: Set tags
id: set_tags
run: |
Expand All @@ -106,7 +112,7 @@ jobs:
push: ${{ inputs.push }}
tags: ${{ steps.set_tags.outputs.tags }}
build-args: |
IMAGE_SOURCE=${{ inputs.base_image_name }}:${{ inputs.base_image_tag }}
IMAGE_SOURCE=${{ inputs.base_image_name }}:${{ steps.extract_base_tag.outputs.first_base_tag }}
- name: List images
if: ${{ inputs.force_build || steps.changes.outputs.image_changed == 'true' }}
run: |
Expand Down

0 comments on commit 17b9b49

Please sign in to comment.