File tree Expand file tree Collapse file tree 2 files changed +7
-10
lines changed
Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Original file line number Diff line number Diff line change 2121 go-version : ' 1.25'
2222
2323 - name : Semantic Release
24+ id : semantic
2425 uses : cycjimmy/semantic-release-action@v4
2526 with :
2627 extra_plugins : |
@@ -29,34 +30,30 @@ jobs:
2930 env :
3031 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
3132
32- docker :
33- runs-on : ubuntu-latest
34- needs : release
35- steps :
36- - uses : actions/checkout@v4
37- with :
38- fetch-depth : 0
39-
4033 - name : Set up Docker Buildx
34+ if : steps.semantic.outputs.new_release_published == 'true'
4135 uses : docker/setup-buildx-action@v3
4236
4337 - name : Login to GHCR
38+ if : steps.semantic.outputs.new_release_published == 'true'
4439 uses : docker/login-action@v3
4540 with :
4641 registry : ghcr.io
4742 username : ${{ github.actor }}
4843 password : ${{ secrets.GITHUB_TOKEN }}
4944
5045 - name : Docker meta
46+ if : steps.semantic.outputs.new_release_published == 'true'
5147 id : meta
5248 uses : docker/metadata-action@v5
5349 with :
5450 images : ghcr.io/${{ github.repository }}
5551 tags : |
56- type=semver,pattern={{version }}
52+ type=raw,value=${{ steps.semantic.outputs.new_release_version }}
5753 type=raw,value=latest
5854
5955 - name : Build and push
56+ if : steps.semantic.outputs.new_release_published == 'true'
6057 uses : docker/build-push-action@v6
6158 with :
6259 context : .
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-w -s" -o terraform-gitlab-drift
1010
1111FROM alpine:3.23.3
1212
13- RUN apk --no-cache add ca-certificates
13+ RUN apk --no-cache add ca-certificates diffutils
1414
1515COPY --from=builder /build/terraform-gitlab-drift /usr/local/bin/terraform-gitlab-drift
1616
You can’t perform that action at this time.
0 commit comments