Skip to content

Commit ad8acfc

Browse files
authored
Merge pull request #43 from fluxcd/update-release-workflow
Update GitHub Actions workflows
2 parents 2ce7a4d + 44b33d8 commit ad8acfc

File tree

4 files changed

+27
-17
lines changed

4 files changed

+27
-17
lines changed

.github/dependabot.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
version: 2
2+
3+
updates:
4+
- package-ecosystem: "github-actions"
5+
directory: "/"
6+
labels: ["area/build"]
7+
schedule:
8+
# by default this will be on a monday.
9+
interval: "weekly"

.github/workflows/release.yaml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
release:
2424
runs-on: ubuntu-latest
2525
steps:
26-
- uses: actions/checkout@v3
26+
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
2727
- name: Prepare
2828
id: prep
2929
run: |
@@ -32,42 +32,42 @@ jobs:
3232
VERSION=${GITHUB_REF/refs\/tags\//}
3333
fi
3434
echo "version=${VERSION}" >> $GITHUB_OUTPUT
35-
- uses: actions/setup-go@v2
35+
- uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # v3.5.0
3636
with:
3737
go-version: 1.20.x
38-
- uses: actions/cache@v2
38+
- uses: actions/cache@69d9d449aced6a2ede0bc19182fadc3a0a42d2b0 # v3.2.6
3939
with:
4040
path: ~/go/pkg/mod
4141
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
4242
restore-keys: |
4343
${{ runner.os }}-go-
44-
- uses: docker/setup-qemu-action@v2
45-
- uses: docker/setup-buildx-action@v2
46-
- uses: sigstore/cosign-installer@main
47-
- uses: anchore/sbom-action/download-syft@v0
44+
- uses: docker/setup-qemu-action@e81a89b1732b9c48d79cd809d8d81d79c4647a18 # v2.1.0
45+
- uses: docker/setup-buildx-action@f03ac48505955848960e80bbb68046aa35c7b9e7 # v2.4.1
46+
- uses: sigstore/cosign-installer@c3667d99424e7e6047999fb6246c0da843953c65 # v3.0.1
47+
- uses: anchore/sbom-action/download-syft@07978da4bdb4faa726e52dfc6b1bed63d4b56479 # v0.13.3
4848
- uses: fluxcd/pkg/actions/kustomize@main
4949
- name: Docker login ghcr.io
50-
uses: docker/#-action@v2
50+
uses: docker/#-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # v2.1.0
5151
with:
5252
registry: ghcr.io
5353
username: fluxcdbot
5454
password: ${{ secrets.GHCR_TOKEN }}
5555
- name: Docker login docker.io
56-
uses: docker/#-action@v2
56+
uses: docker/#-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # v2.1.0
5757
with:
5858
username: fluxcdbot
5959
password: ${{ secrets.DOCKER_FLUXCD_PASSWORD }}
6060
- name: Docker meta
6161
id: meta
62-
uses: docker/metadata-action@v4
62+
uses: docker/metadata-action@507c2f2dc502c992ad446e3d7a5dfbe311567a96 # v4.3.0
6363
with:
6464
images: |
6565
fluxcd/${{ env.CONTROLLER }}
6666
ghcr.io/fluxcd/${{ env.CONTROLLER }}
6767
tags: |
6868
type=raw,value=${{ steps.prep.outputs.version }}
6969
- name: Docker push
70-
uses: docker/build-push-action@v2
70+
uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 # v4.0.0
7171
with:
7272
push: true
7373
builder: ${{ steps.buildx.outputs.name }}
@@ -80,11 +80,11 @@ jobs:
8080
env:
8181
COSIGN_EXPERIMENTAL: 1
8282
run: |
83-
cosign sign fluxcd/${{ env.CONTROLLER }}:${{ steps.prep.outputs.version }}
84-
cosign sign ghcr.io/fluxcd/${{ env.CONTROLLER }}:${{ steps.prep.outputs.version }}
83+
cosign sign --yes fluxcd/${{ env.CONTROLLER }}:${{ steps.prep.outputs.version }}
84+
cosign sign --yes ghcr.io/fluxcd/${{ env.CONTROLLER }}:${{ steps.prep.outputs.version }}
8585
- name: GoReleaser publish signed SBOM
8686
if: startsWith(github.ref, 'refs/tags/v')
87-
uses: goreleaser/goreleaser-action@v3
87+
uses: goreleaser/goreleaser-action@f82d6c1c344bcacabba2c841718984797f664a6b # v4.2.0
8888
with:
8989
version: latest
9090
args: release --rm-dist --skip-validate

.github/workflows/test.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,16 @@ jobs:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- name: Checkout
16-
uses: actions/checkout@v3
16+
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
1717
- name: Restore Go cache
18-
uses: actions/cache@v2
18+
uses: actions/cache@69d9d449aced6a2ede0bc19182fadc3a0a42d2b0 # v3.2.6
1919
with:
2020
path: ~/go/pkg/mod
2121
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
2222
restore-keys: |
2323
${{ runner.os }}-go-
2424
- name: Setup Go
25-
uses: actions/setup-go@v2
25+
uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # v3.5.0
2626
with:
2727
go-version: 1.20.x
2828
- name: Run tests

.goreleaser.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ signs:
4141
certificate: '${artifact}.pem'
4242
args:
4343
- sign-blob
44+
- "--yes"
4445
- '--output-certificate=${certificate}'
4546
- '--output-signature=${signature}'
4647
- '${artifact}'

0 commit comments

Comments
 (0)