Skip to content

Commit a68eb2e

Browse files
Update dependencies to latest versions in go.mod and go.sum (#179)
* chore: update dependencies to latest versions in go.mod and go.sum * chore: update GitHub Actions workflows for release and testing, including dependency upgrades and matrix strategy
1 parent 5ef718f commit a68eb2e

4 files changed

Lines changed: 137 additions & 75 deletions

File tree

.github/workflows/release-pullrequest.yaml

Lines changed: 30 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -7,59 +7,66 @@ on:
77

88
env:
99
GHCR_REPO: ghcr.io/${{ github.repository }}
10-
LOCAL_KIND: false
1110

1211
jobs:
1312
build:
14-
runs-on: ubuntu-latest
13+
name: Build and Push
14+
strategy:
15+
matrix:
16+
runner: [ubuntu-22.04-arm, ubuntu-22.04]
17+
include:
18+
- runner: ubuntu-22.04-arm
19+
platform: linux/arm64
20+
- runner: ubuntu-22.04
21+
platform: linux/amd64
22+
runs-on: ${{ matrix.runner }}
1523

1624
permissions:
1725
contents: read
1826
packages: write
1927

2028
steps:
21-
- name: Checkout
22-
uses: actions/checkout@v4
29+
- name: Prepare
30+
run: |
31+
platform=${{ matrix.platform }}
32+
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
2333
2434
- name: Docker meta
2535
id: meta
26-
uses: docker/metadata-action@v5
36+
uses: docker/metadata-action@v6
2737
with:
2838
images: ${{ env.GHCR_REPO }}
2939

30-
- name: Set up QEMU
31-
uses: docker/setup-qemu-action@v3
40+
- name: Login to GHCR
41+
uses: docker/login-action@v4
42+
with:
43+
registry: ghcr.io
44+
username: ${{ github.repository_owner }}
45+
password: ${{ secrets.GITHUB_TOKEN }}
3246

3347
- name: Set up Docker Buildx
34-
uses: docker/setup-buildx-action@v3
48+
uses: docker/setup-buildx-action@v4
3549

36-
- name: Build (no push)
37-
uses: docker/build-push-action@v5
50+
- name: Build and NOT push
51+
id: build
52+
uses: docker/build-push-action@v7
3853
with:
54+
platforms: ${{ matrix.platform }}
3955
push: false
40-
load: ${{ env.LOCAL_KIND == 'true' }}
41-
no-cache: ${{ env.LOCAL_KIND == 'true' }}
42-
platforms: ${{ env.LOCAL_KIND == 'true' && 'linux/amd64' || 'linux/amd64,linux/arm64' }}
43-
tags: ${{ steps.meta.outputs.tags }}
4456
labels: ${{ steps.meta.outputs.labels }}
45-
build-args: |
46-
CACHEBUST=${{ github.sha }}
47-
COMMIT_HASH=${{ github.sha }}
48-
cache-from: ${{ env.LOCAL_KIND == 'true' && '' || 'type=gha' }}
49-
cache-to: ${{ env.LOCAL_KIND == 'true' && '' || 'type=gha,mode=max' }}
5057

5158
test:
5259
runs-on: ubuntu-latest
5360
steps:
54-
- uses: actions/checkout@v4
55-
- uses: actions/setup-go@v5
61+
- uses: actions/checkout@v6
62+
- uses: actions/setup-go@v6
5663
with:
5764
go-version: 'stable'
5865
- name: Gather dependencies
5966
run: go mod download
6067
- name: Run coverage
61-
run: go test -race -tags=unit,integration -p 1 -coverprofile=coverage.txt -covermode=atomic ./...
68+
run: go test -race -tags=unit,integration -p 1 -timeout 30m -coverprofile=coverage.txt -covermode=atomic ./... -coverpkg=./...
6269
- name: Upload coverage to Codecov
63-
uses: codecov/codecov-action@v4
70+
uses: codecov/codecov-action@v6
6471
with:
6572
token: ${{ secrets.CODECOV_TOKEN }}

.github/workflows/release-tag.yaml

Lines changed: 86 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -2,72 +2,127 @@ name: release-tag
22

33
on:
44
push:
5-
tags: [ '[0-9]+.[0-9]+.[0-9]+', '[0-9]+.[0-9]+.[0-9]+-*' ] # Matches standard versions and pre-release suffixes
5+
tags: [ '[0-9]+.[0-9]+.[0-9]+', '[0-9]+.[0-9]+.[0-9]+-*' ]
66

77
env:
88
GHCR_REPO: ghcr.io/${{ github.repository }}
9-
DOCKER_PUSH: true
10-
LOCAL_KIND: false
119

1210
jobs:
13-
build-and-push:
14-
runs-on: ubuntu-latest
15-
11+
build:
12+
name: Build and Push
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
runner: [ubuntu-22.04-arm, ubuntu-22.04]
17+
include:
18+
- runner: ubuntu-22.04-arm
19+
platform: linux/arm64
20+
- runner: ubuntu-22.04
21+
platform: linux/amd64
22+
runs-on: ${{ matrix.runner }}
23+
1624
permissions:
1725
contents: read
1826
packages: write
1927

2028
steps:
21-
- name: Checkout
22-
uses: actions/checkout@v4
29+
- name: Prepare
30+
run: |
31+
platform=${{ matrix.platform }}
32+
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
2333
2434
- name: Docker meta
2535
id: meta
26-
uses: docker/metadata-action@v5
36+
uses: docker/metadata-action@v6
2737
with:
2838
images: ${{ env.GHCR_REPO }}
2939

3040
- name: Login to GHCR
31-
if: env.DOCKER_PUSH == 'true'
32-
uses: docker/login-action@v3
41+
uses: docker/login-action@v4
3342
with:
3443
registry: ghcr.io
3544
username: ${{ github.repository_owner }}
3645
password: ${{ secrets.GITHUB_TOKEN }}
3746

38-
- name: Set up QEMU
39-
uses: docker/setup-qemu-action@v3
40-
4147
- name: Set up Docker Buildx
42-
uses: docker/setup-buildx-action@v3
48+
uses: docker/setup-buildx-action@v4
4349

44-
- name: Build and push
45-
uses: docker/build-push-action@v5
50+
- name: Build and push by digest
51+
id: build
52+
uses: docker/build-push-action@v7
4653
with:
47-
push: ${{ env.DOCKER_PUSH == 'true' }}
48-
load: ${{ env.LOCAL_KIND == 'true' }}
49-
no-cache: ${{ env.LOCAL_KIND == 'true' }}
50-
platforms: ${{ env.LOCAL_KIND == 'true' && 'linux/amd64' || 'linux/amd64,linux/arm64' }}
51-
tags: ${{ steps.meta.outputs.tags }}
54+
platforms: ${{ matrix.platform }}
55+
push: true
5256
labels: ${{ steps.meta.outputs.labels }}
53-
build-args: |
54-
CACHEBUST=${{ github.sha }}
55-
COMMIT_HASH=${{ github.sha }}
56-
cache-from: ${{ env.LOCAL_KIND == 'true' && '' || 'type=gha' }}
57-
cache-to: ${{ env.LOCAL_KIND == 'true' && '' || 'type=gha,mode=max' }}
57+
outputs: type=image,"name=${{ env.GHCR_REPO }}",push-by-digest=true,name-canonical=true,push=true
58+
59+
- name: Export digest
60+
run: |
61+
mkdir -p /tmp/digests
62+
digest="${{ steps.build.outputs.digest }}"
63+
touch "/tmp/digests/${digest#sha256:}"
64+
65+
- name: Upload digest
66+
uses: actions/upload-artifact@v7
67+
with:
68+
name: digests-${{ env.PLATFORM_PAIR }}
69+
path: /tmp/digests/*
70+
if-no-files-found: error
71+
retention-days: 1
72+
73+
merge:
74+
runs-on: ubuntu-latest
75+
needs:
76+
- build
77+
permissions:
78+
contents: read
79+
packages: write
80+
steps:
81+
- name: Download digests
82+
uses: actions/download-artifact@v8
83+
with:
84+
path: /tmp/digests
85+
pattern: digests-*
86+
merge-multiple: true
87+
88+
- name: Login to GHCR
89+
uses: docker/login-action@v4
90+
with:
91+
registry: ghcr.io
92+
username: ${{ github.repository_owner }}
93+
password: ${{ secrets.GITHUB_TOKEN }}
94+
95+
- name: Set up Docker Buildx
96+
uses: docker/setup-buildx-action@v4
97+
98+
- name: Docker meta
99+
id: meta
100+
uses: docker/metadata-action@v6
101+
with:
102+
images: ${{ env.GHCR_REPO }}
103+
104+
- name: Create manifest list and push
105+
working-directory: /tmp/digests
106+
run: |
107+
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
108+
$(printf '${{ env.GHCR_REPO }}@sha256:%s ' *)
109+
110+
- name: Inspect image
111+
run: |
112+
docker buildx imagetools inspect ${{ env.GHCR_REPO }}:${{ steps.meta.outputs.version }}
58113
59114
test:
60115
runs-on: ubuntu-latest
61116
steps:
62-
- uses: actions/checkout@v4
63-
- uses: actions/setup-go@v5
117+
- uses: actions/checkout@v6
118+
- uses: actions/setup-go@v6
64119
with:
65120
go-version: 'stable'
66121
- name: Gather dependencies
67122
run: go mod download
68123
- name: Run coverage
69-
run: go test -race -tags=unit,integration -p 1 -coverprofile=coverage.txt -covermode=atomic ./...
124+
run: go test -race -tags=unit,integration -p 1 -timeout 30m -coverprofile=coverage.txt -covermode=atomic ./... -coverpkg=./...
70125
- name: Upload coverage to Codecov
71-
uses: codecov/codecov-action@v4
126+
uses: codecov/codecov-action@v6
72127
with:
73128
token: ${{ secrets.CODECOV_TOKEN }}

go.mod

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ require (
66
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc
77
github.com/go-logr/logr v1.4.3
88
github.com/gobuffalo/flect v1.0.3
9-
github.com/krateoplatformops/plumbing v1.6.0
9+
github.com/krateoplatformops/plumbing v1.7.2
1010
github.com/krateoplatformops/unstructured-runtime v1.0.1
1111
github.com/stretchr/testify v1.11.1
1212
k8s.io/api v0.35.2
13-
k8s.io/apiextensions-apiserver v0.35.0
13+
k8s.io/apiextensions-apiserver v0.35.1
1414
k8s.io/apimachinery v0.35.2
1515
k8s.io/client-go v0.35.2
1616
sigs.k8s.io/e2e-framework v0.6.0
@@ -123,13 +123,13 @@ require (
123123
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
124124
gopkg.in/inf.v0 v0.9.1 // indirect
125125
gopkg.in/yaml.v3 v3.0.1 // indirect
126-
helm.sh/helm/v3 v3.20.0 // indirect
127-
k8s.io/apiserver v0.35.0 // indirect
128-
k8s.io/cli-runtime v0.35.0 // indirect
129-
k8s.io/component-base v0.35.0 // indirect
126+
helm.sh/helm/v3 v3.20.2 // indirect
127+
k8s.io/apiserver v0.35.1 // indirect
128+
k8s.io/cli-runtime v0.35.1 // indirect
129+
k8s.io/component-base v0.35.1 // indirect
130130
k8s.io/klog/v2 v2.130.1 // indirect
131131
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 // indirect
132-
k8s.io/kubectl v0.35.0 // indirect
132+
k8s.io/kubectl v0.35.1 // indirect
133133
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 // indirect
134134
oras.land/oras-go/v2 v2.6.0 // indirect
135135
sigs.k8s.io/controller-runtime v0.22.3 // indirect

go.sum

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,8 @@ github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
167167
github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk=
168168
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
169169
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
170-
github.com/krateoplatformops/plumbing v1.6.0 h1:bCS9FLE5JjLEdsn9Ei+HfTLHySil+ne7VLW0zKOSBpg=
171-
github.com/krateoplatformops/plumbing v1.6.0/go.mod h1:L8dMKmq9hO1tz9NzJPlryBj618J5w0PYt8z6fzAbBvs=
170+
github.com/krateoplatformops/plumbing v1.7.2 h1:I9rvpKPQ1eswRZkdwCT+xfdDRLODSsL1c7a6g8K3S9c=
171+
github.com/krateoplatformops/plumbing v1.7.2/go.mod h1:UrYvAvnfacOiOLlQbIg6J08zYC+XJ9ZMKbecQq+4jV4=
172172
github.com/krateoplatformops/unstructured-runtime v1.0.1 h1:ureSvhxqVTGtS92p0d+TakC7X7osvq5ExbX2334OdCs=
173173
github.com/krateoplatformops/unstructured-runtime v1.0.1/go.mod h1:k85I4xvMIMSlmNbQN93hF5PHBegPqGV4nHZaKCF0/Nk=
174174
github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc=
@@ -396,28 +396,28 @@ gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
396396
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
397397
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
398398
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
399-
helm.sh/helm/v3 v3.20.0 h1:2M+0qQwnbI1a2CxN7dbmfsWHg/MloeaFMnZCY56as50=
400-
helm.sh/helm/v3 v3.20.0/go.mod h1:rTavWa0lagZOxGfdhu4vgk1OjH2UYCnrDKE2PVC4N0o=
399+
helm.sh/helm/v3 v3.20.2 h1:binM4rvPx5DcNsa1sIt7UZi55lRbu3pZUFmQkSoRh48=
400+
helm.sh/helm/v3 v3.20.2/go.mod h1:Fl1kBaWCpkUrM6IYXPjQ3bdZQfFrogKArqptvueZ6Ww=
401401
k8s.io/api v0.35.2 h1:tW7mWc2RpxW7HS4CoRXhtYHSzme1PN1UjGHJ1bdrtdw=
402402
k8s.io/api v0.35.2/go.mod h1:7AJfqGoAZcwSFhOjcGM7WV05QxMMgUaChNfLTXDRE60=
403-
k8s.io/apiextensions-apiserver v0.35.0 h1:3xHk2rTOdWXXJM+RDQZJvdx0yEOgC0FgQ1PlJatA5T4=
404-
k8s.io/apiextensions-apiserver v0.35.0/go.mod h1:E1Ahk9SADaLQ4qtzYFkwUqusXTcaV2uw3l14aqpL2LU=
403+
k8s.io/apiextensions-apiserver v0.35.1 h1:p5vvALkknlOcAqARwjS20kJffgzHqwyQRM8vHLwgU7w=
404+
k8s.io/apiextensions-apiserver v0.35.1/go.mod h1:2CN4fe1GZ3HMe4wBr25qXyJnJyZaquy4nNlNmb3R7AQ=
405405
k8s.io/apimachinery v0.35.2 h1:NqsM/mmZA7sHW02JZ9RTtk3wInRgbVxL8MPfzSANAK8=
406406
k8s.io/apimachinery v0.35.2/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns=
407-
k8s.io/apiserver v0.35.0 h1:CUGo5o+7hW9GcAEF3x3usT3fX4f9r8xmgQeCBDaOgX4=
408-
k8s.io/apiserver v0.35.0/go.mod h1:QUy1U4+PrzbJaM3XGu2tQ7U9A4udRRo5cyxkFX0GEds=
409-
k8s.io/cli-runtime v0.35.0 h1:PEJtYS/Zr4p20PfZSLCbY6YvaoLrfByd6THQzPworUE=
410-
k8s.io/cli-runtime v0.35.0/go.mod h1:VBRvHzosVAoVdP3XwUQn1Oqkvaa8facnokNkD7jOTMY=
407+
k8s.io/apiserver v0.35.1 h1:potxdhhTL4i6AYAa2QCwtlhtB1eCdWQFvJV6fXgJzxs=
408+
k8s.io/apiserver v0.35.1/go.mod h1:BiL6Dd3A2I/0lBnteXfWmCFobHM39vt5+hJQd7Lbpi4=
409+
k8s.io/cli-runtime v0.35.1 h1:uKcXFe8J7AMAM4Gm2JDK4mp198dBEq2nyeYtO+JfGJE=
410+
k8s.io/cli-runtime v0.35.1/go.mod h1:55/hiXIq1C8qIJ3WBrWxEwDLdHQYhBNRdZOz9f7yvTw=
411411
k8s.io/client-go v0.35.2 h1:YUfPefdGJA4aljDdayAXkc98DnPkIetMl4PrKX97W9o=
412412
k8s.io/client-go v0.35.2/go.mod h1:4QqEwh4oQpeK8AaefZ0jwTFJw/9kIjdQi0jpKeYvz7g=
413-
k8s.io/component-base v0.35.0 h1:+yBrOhzri2S1BVqyVSvcM3PtPyx5GUxCK2tinZz1G94=
414-
k8s.io/component-base v0.35.0/go.mod h1:85SCX4UCa6SCFt6p3IKAPej7jSnF3L8EbfSyMZayJR0=
413+
k8s.io/component-base v0.35.1 h1:XgvpRf4srp037QWfGBLFsYMUQJkE5yMa94UsJU7pmcE=
414+
k8s.io/component-base v0.35.1/go.mod h1:HI/6jXlwkiOL5zL9bqA3en1Ygv60F03oEpnuU1G56Bs=
415415
k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk=
416416
k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE=
417417
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 h1:Y3gxNAuB0OBLImH611+UDZcmKS3g6CthxToOb37KgwE=
418418
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912/go.mod h1:kdmbQkyfwUagLfXIad1y2TdrjPFWp2Q89B3qkRwf/pQ=
419-
k8s.io/kubectl v0.35.0 h1:cL/wJKHDe8E8+rP3G7avnymcMg6bH6JEcR5w5uo06wc=
420-
k8s.io/kubectl v0.35.0/go.mod h1:VR5/TSkYyxZwrRwY5I5dDq6l5KXmiCb+9w8IKplk3Qo=
419+
k8s.io/kubectl v0.35.1 h1:zP3Er8C5i1dcAFUMh9Eva0kVvZHptXIn/+8NtRWMxwg=
420+
k8s.io/kubectl v0.35.1/go.mod h1:cQ2uAPs5IO/kx8R5s5J3Ihv3VCYwrx0obCXum0CvnXo=
421421
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 h1:SjGebBtkBqHFOli+05xYbK8YF1Dzkbzn+gDM4X9T4Ck=
422422
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
423423
oras.land/oras-go/v2 v2.6.0 h1:X4ELRsiGkrbeox69+9tzTu492FMUu7zJQW6eJU+I2oc=

0 commit comments

Comments
 (0)