File tree Expand file tree Collapse file tree 1 file changed +7
-9
lines changed
Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -54,14 +54,12 @@ jobs:
5454 tags : ${{ steps.meta.outputs.tags }}
5555 labels : ${{ steps.meta.outputs.labels }}
5656
57- - name : Extract first image tag
58- id : extract_tag
59- run : |
60- echo "tag=$(echo '${{ steps.meta.outputs.tags }}' | head -n1)" >> $GITHUB_OUTPUT
61-
6257 - name : Test Docker image
58+ env :
59+ # Use the first tag from the metadata output (branch-specific tag)
60+ IMAGE_TAG : ${{ fromJSON(steps.meta.outputs.tags)[0] }}
6361 run : |
64- echo "Testing image: ${{ steps.extract_tag.outputs.tag }} "
65- docker run --rm ${{ steps.extract_tag.outputs.tag }} terraform --version
66- docker run --rm ${{ steps.extract_tag.outputs.tag }} terraform-docs --version
67- docker run --rm ${{ steps.extract_tag.outputs.tag }} tflint --version
62+ echo "Testing image: $IMAGE_TAG "
63+ docker run --rm $IMAGE_TAG terraform --version
64+ docker run --rm $IMAGE_TAG terraform-docs --version
65+ docker run --rm $IMAGE_TAG tflint --version
You can’t perform that action at this time.
0 commit comments