Skip to content

Commit 6338f47

Browse files
committed
chore: Update Docker actions to latest versions
1 parent 116ed00 commit 6338f47

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

Diff for: .github/workflows/docker-cd.yml

+14-9
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: CD - Publish Docker image on ghcr.io
22

3-
# This workflow uses actions that are not certified by GitHub.
4-
# They are provided by a third-party and are governed by
3+
# cos
54
# separate terms of service, privacy policy, and support
65
# documentation.
76

@@ -32,39 +31,45 @@ jobs:
3231

3332
name: build-image
3433
steps:
35-
- uses: actions/checkout@v3.6.0
34+
- uses: actions/checkout@v4.1.7
3635
with:
3736
fetch-depth: 1
3837

3938
- name: Install Cosign
4039
uses: sigstore/[email protected]
40+
# with:
41+
# cosign-release: 'v2.2.4' # optional
4142

4243
- name: Set up QEMU
43-
uses: docker/setup-qemu-action@v2.2.0
44+
uses: docker/setup-qemu-action@v3.2.0
4445

4546
- name: Set up Docker Buildx
46-
uses: docker/setup-buildx-action@v2.10.0
47+
uses: docker/setup-buildx-action@v3.5.0
4748

4849
- name: Login to GitHub Container Registry
49-
uses: docker/login-action@v2.2.0
50+
uses: docker/login-action@v3.3.0
5051
with:
51-
registry: ghcr.io
52+
registry: ${{ env.REGISTRY }}
5253
username: ${{ github.actor }}
5354
password: ${{ secrets.GITHUB_TOKEN }}
5455

5556
- id: docker_meta
5657
uses: docker/[email protected]
5758
with:
58-
images: ghcr.io/sigstore/sample-honk
59+
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
5960
tags: type=sha,format=long
6061

6162
- name: Build and Push container images
62-
uses: docker/build-push-action@v4.2.1
63+
uses: docker/build-push-action@v6.5.0
6364
id: build-and-push
6465
with:
6566
platforms: linux/amd64,linux/arm64
6667
push: true
6768
tags: ${{ steps.docker_meta.outputs.tags }}
69+
labels: ${{ steps.docker_meta.outputs.labels }}
70+
cache-from: type=gha
71+
cache-to: type=gha,mode=max
72+
# outputs: type=image,name=target,annotation-index.org.opencontainers.image.description=${{ fromJSON(steps.docker_meta.outputs.json).labels['org.opencontainers.image.description'] }}
6873

6974
# https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#using-an-intermediate-environment-variable
7075
- name: Sign image with a key

Diff for: cosign.pub

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
-----BEGIN PUBLIC KEY-----
2+
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE/6fPQhwVsFvcfGtSFBIwdHbTxkF3
3+
KaNOdpXBpmyrM/y1TM5YgTYl5mVq7km/LPukbXslcrVX1dT5H+FUP6+onQ==
4+
-----END PUBLIC KEY-----

0 commit comments

Comments
 (0)