Skip to content

Commit 88fcc2c

Browse files
committed
Add metadata to docker hub
1 parent b8715ce commit 88fcc2c

File tree

1 file changed

+18
-39
lines changed

1 file changed

+18
-39
lines changed

.github/workflows/docker-release.yml

Lines changed: 18 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -37,19 +37,19 @@ jobs:
3737
username: ${{ secrets.DOCKER_USER }}
3838
password: ${{ secrets.DOCKER_TOKEN }}
3939

40-
#- name: Login - Quay.io
41-
# uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3
42-
# with:
43-
# registry: quay.io
44-
# username: ${{ github.repository_owner }}
45-
# password: ${{ secrets.QUAY_TOKEN }}
40+
- name: Login - Quay.io
41+
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3
42+
with:
43+
registry: quay.io
44+
username: ${{ github.repository_owner }}
45+
password: ${{ secrets.QUAY_TOKEN }}
4646

47-
#- name: Login - GHCR.io
48-
# uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3
49-
# with:
50-
# registry: ghcr.io
51-
# username: ${{ github.repository_owner }}
52-
# password: ${{ secrets.GH_PAT }}
47+
- name: Login - GHCR.io
48+
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3
49+
with:
50+
registry: ghcr.io
51+
username: ${{ github.repository_owner }}
52+
password: ${{ secrets.GH_PAT }}
5353

5454
- name: Extract metadata (tags, labels) for Docker
5555
id: meta
@@ -67,32 +67,11 @@ jobs:
6767
tags: ${{ steps.meta.outputs.tags }}
6868
labels: ${{ steps.meta.outputs.labels }}
6969

70-
#- name: Generate artifact attestation
71-
# uses: actions/attest-build-provenance@v2
72-
# with:
73-
# subject-name: index.docker.io/helvethink/gitlab-ci-exporter
74-
# subject-digest: ${{ steps.push.outputs.digest }}
75-
# push-to-registry: true
76-
77-
# Quay / Buidah build
78-
- name: Build Image
79-
id: build-image
80-
uses: redhat-actions/buildah-build@v2
81-
with:
82-
image: gitlab-ci-exporter
83-
tags: ${{ steps.meta.outputs.tags }} ${{ github.sha }}
84-
containerfiles: |
85-
./Dockerfile
86-
87-
- name: Push To quay.io
88-
id: push-to-quay
89-
uses: redhat-actions/push-to-registry@v2
70+
- name: Generate artifact attestation
71+
uses: actions/attest-build-provenance@v2
9072
with:
91-
image: ${{ steps.build-image.outputs.image }}
92-
tags: ${{ steps.meta.outputs.tags }}
93-
registry: quay.io/helvethink/
94-
username: ${{ secrets.QUAY_USER }}
95-
password: ${{ secrets.QUAY_TOKEN }}
73+
subject-name: index.docker.io/helvethink/gitlab-ci-exporter
74+
subject-digest: ${{ steps.push.outputs.digest }}
75+
push-to-registry: true
9676

97-
- name: Print image url
98-
run: echo "Image pushed to ${{ steps.push-to-quay.outputs.registry-paths }}"
77+
# Quay / Buidah build

0 commit comments

Comments
 (0)