Skip to content

Commit 8f338b7

Browse files
authored
Upgrade golangci-lint, trivy, kubectl, gh cli, sops, trivy (#2259)
Summary: Upgrade golangci-lint, trivy, kubectl, gh cli, sops, trivy TSIA Relevant Issues: N/A Type of change: /kind dependency Test Plan: Verified the following - [x] `CGO_ENABLED=0 golangci-lint run` succeeds - [x] Verified `kubectl` no longer errors on newer clusters (previous version too old) - [x] sops decrypts secrets as expected --------- Signed-off-by: Dom Del Nano <ddelnano@gmail.com>
1 parent 3673bf5 commit 8f338b7

File tree

10 files changed

+46
-46
lines changed

10 files changed

+46
-46
lines changed

docker.properties

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
DOCKER_IMAGE_TAG=202508081946
2-
LINTER_IMAGE_DIGEST=85a928e7607ef9c0c78f7aa421b04e328d5085bb1698bcf7eec1dcb6d609e3c8
3-
DEV_IMAGE_DIGEST=4a116347d80d330e978d57552a9a49258fd615912cd8f94398a2281bb7e362eb
4-
DEV_IMAGE_WITH_EXTRAS_DIGEST=5b60b6fa4a98265da41a8ec4ec363bf946fd1b5d7b977d46bd6c6d941e183816
1+
DOCKER_IMAGE_TAG=202508131912
2+
LINTER_IMAGE_DIGEST=db3238ae3ab3f0fe307aef8920a29b5f0df808248c16a1650baa228c4cefbd4c
3+
DEV_IMAGE_DIGEST=42c7f00b68db0835c266c5aceb6f67ec7e43342336f95218af14e19858e08854
4+
DEV_IMAGE_WITH_EXTRAS_DIGEST=bbcd6dc6d269231163be9782d42bdf2b2855a34ab384a853fa67e13e946948ec

src/e2e_test/perf_tool/pkg/metrics/data_loss_handler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ func (h *dataLossHandler) HandleDone(ctx context.Context) error {
8484

8585
func (h *dataLossHandler) sendRows(ctx context.Context) error {
8686
ts := h.lastTimestamp
87-
if (ts == time.Time{}) {
87+
if (ts.Equal(time.Time{})) {
8888
ts = time.Now()
8989
}
9090
percentRow := newResultRow()

src/e2e_test/perf_tool/pkg/metrics/prometheus_recorder.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ func (r *prometheusRecorderImpl) scrapeFunc(fw *forwarder) func() error {
126126
continue
127127
}
128128
// Only collect counters and gauges for now.
129-
if !(mf.GetType() == io_prometheus_client.MetricType_COUNTER || mf.GetType() == io_prometheus_client.MetricType_GAUGE) {
129+
if mf.GetType() != io_prometheus_client.MetricType_COUNTER && mf.GetType() != io_prometheus_client.MetricType_GAUGE {
130130
continue
131131
}
132132
for _, m := range mf.GetMetric() {

src/shared/artifacts/manifest/query.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ var ErrArtifactSetNotFound = errors.New("no artifact set with given artifact nam
3434
var ErrArtifactNotFound = errors.New("no artifact with given version")
3535

3636
// GetArtifact returns a an artifact with the given artifact name and version string.
37-
func (m *ArtifactManifest) GetArtifact(name string, version string) (*versionspb.Artifact, error) {
38-
as, ok := m.sets[name]
37+
func (a *ArtifactManifest) GetArtifact(name string, version string) (*versionspb.Artifact, error) {
38+
as, ok := a.sets[name]
3939
if !ok {
4040
return nil, ErrArtifactSetNotFound
4141
}
@@ -50,8 +50,8 @@ func (m *ArtifactManifest) GetArtifact(name string, version string) (*versionspb
5050
type ArtifactFilter func(*versionspb.Artifact) bool
5151

5252
// ListArtifacts returns artifacts with the given name, in version sorted order (newest versions first). It returns up to `limit` artifacts.
53-
func (m *ArtifactManifest) ListArtifacts(name string, limit int64, filters ...ArtifactFilter) ([]*versionspb.Artifact, error) {
54-
as, ok := m.sets[name]
53+
func (a *ArtifactManifest) ListArtifacts(name string, limit int64, filters ...ArtifactFilter) ([]*versionspb.Artifact, error) {
54+
as, ok := a.sets[name]
5555
if !ok {
5656
return nil, ErrArtifactSetNotFound
5757
}

src/shared/services/election/election.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,17 +55,17 @@ type K8sLeaderElectionMgr struct {
5555
}
5656

5757
// NewK8sLeaderElectionMgr creates a K8sLeaderElectionMgr.
58-
func NewK8sLeaderElectionMgr(electionNamespace string, expectedMaxSkewMS, renewDeadlineMS time.Duration, electionName string) (*K8sLeaderElectionMgr, error) {
58+
func NewK8sLeaderElectionMgr(electionNamespace string, expectedMaxSkew, renewDuration time.Duration, electionName string) (*K8sLeaderElectionMgr, error) {
5959
if electionNamespace == "" {
6060
return nil, errors.New("namespace must be specified for leader election")
6161
}
6262
// Might add more complex logic that necessitates errors, but for now not included.
6363
return &K8sLeaderElectionMgr{
6464
namespace: electionNamespace,
6565
name: electionName,
66-
leaseDuration: expectedMaxSkewMS + renewDeadlineMS,
67-
renewDeadline: renewDeadlineMS,
68-
retryPeriod: renewDeadlineMS / 4,
66+
leaseDuration: expectedMaxSkew + renewDuration,
67+
renewDeadline: renewDuration,
68+
retryPeriod: renewDuration / 4,
6969
kubeConfig: "",
7070
}, nil
7171
}

src/utils/artifacts/versions_gen/main.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@ func init() {
4747
}
4848

4949
func availableArtifacts(artifactName string) []vpb.ArtifactType {
50-
switch {
51-
case artifactName == "cli":
50+
switch artifactName {
51+
case "cli":
5252
return []vpb.ArtifactType{vpb.AT_LINUX_AMD64, vpb.AT_DARWIN_AMD64}
53-
case artifactName == "vizier":
53+
case "vizier":
5454
return []vpb.ArtifactType{vpb.AT_CONTAINER_SET_LINUX_AMD64, vpb.AT_CONTAINER_SET_YAMLS, vpb.AT_CONTAINER_SET_TEMPLATE_YAMLS}
55-
case artifactName == "operator":
55+
case "operator":
5656
return []vpb.ArtifactType{vpb.AT_CONTAINER_SET_LINUX_AMD64, vpb.AT_CONTAINER_SET_TEMPLATE_YAMLS}
5757
default:
5858
panic(fmt.Sprintf("Unknown artifact type: %s", artifactName))

tools/chef/cookbooks/px_dev/attributes/linux.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,9 @@
3838
'bbca37cc395c974ffa4893ee35819ad23ebb27426df87af92e93a9ec66ef8712'
3939

4040
default['golangci-lint']['download_path'] =
41-
'https://github.com/golangci/golangci-lint/releases/download/v2.0.2/golangci-lint-2.0.2-linux-amd64.tar.gz'
41+
'https://github.com/golangci/golangci-lint/releases/download/v2.3.1/golangci-lint-2.3.1-linux-amd64.tar.gz'
4242
default['golangci-lint']['sha256'] =
43-
'89cc8a7810dc63b9a37900da03e37c3601caf46d42265d774e0f1a5d883d53e2'
43+
'57c3a4c56b8363f7f1f695ac957b0bb474aca00c490bc5e949669a6c2ba5c432'
4444

4545
default['nodejs']['download_path'] =
4646
'https://nodejs.org/dist/v18.16.0/node-v18.16.0-linux-x64.tar.xz'

tools/chef/cookbooks/px_dev/attributes/mac_os_x.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@
3939
'4a8d7a32052f223e71faab424a69430455b27b3fff5f4e651f9d97c3e51a8746'
4040

4141
default['golangci-lint']['download_path'] =
42-
'https://github.com/golangci/golangci-lint/releases/download/v2.0.2/golangci-lint-2.0.2-darwin-amd64.tar.gz'
42+
'https://github.com/golangci/golangci-lint/releases/download/v2.3.1/golangci-lint-2.3.1-darwin-amd64.tar.gz'
4343
default['golangci-lint']['sha256'] =
44-
'a88cbdc86b483fe44e90bf2dcc3fec2af8c754116e6edf0aa6592cac5baa7a0e'
44+
'2f4412ffa77cb58ab3a7d065e1fff01ab714bb2b6fa06ad16ed793b6fc8d534d'
4545

4646
default['nodejs']['download_path'] =
4747
'https://nodejs.org/dist/v18.16.0/node-v18.16.0-darwin-x64.tar.gz'

tools/chef/cookbooks/px_dev_extras/attributes/linux.rb

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,19 @@
3333
'6c9234d0b2b024bf0e7c845fc092339b51b94e5addeee9612a7219cfd2a7b731'
3434

3535
default['gh']['download_path'] =
36-
'https://github.com/cli/cli/releases/download/v2.26.1/gh_2.26.1_linux_amd64.tar.gz'
36+
'https://github.com/cli/cli/releases/download/v2.76.1/gh_2.76.1_linux_amd64.tar.gz'
3737
default['gh']['sha256'] =
38-
'4e1f98c10eb0af2c3bfe6849c10328a2a2446a9ff4294db0dfdb20b7d16eaecc'
38+
'18367ca38b4462889ae38fba6a18c53a4c2818b6af309bbe53d0810bb06036e9'
3939

4040
default['helm']['download_path'] =
4141
'https://get.helm.sh/helm-v3.11.3-linux-amd64.tar.gz'
4242
default['helm']['sha256'] =
4343
'ca2d5d40d4cdfb9a3a6205dd803b5bc8def00bd2f13e5526c127e9b667974a89'
4444

4545
default['kubectl']['download_path'] =
46-
'https://storage.googleapis.com/kubernetes-release/release/v1.26.0/bin/linux/amd64/kubectl'
46+
'https://dl.k8s.io/release/v1.33.3/bin/linux/amd64/kubectl'
4747
default['kubectl']['sha256'] =
48-
'b6769d8ac6a0ed0f13b307d289dc092ad86180b08f5b5044af152808c04950ae'
48+
'2fcf65c64f352742dc253a25a7c95617c2aba79843d1b74e585c69fe4884afb0'
4949

5050
default['kustomize']['download_path'] =
5151
'https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2Fv5.0.3/kustomize_v5.0.3_linux_amd64.tar.gz'
@@ -58,9 +58,9 @@
5858
'd6a6dbf82ae9a1a7f9fbc8d85c224617a17337afa4284aaca6b0556a7347609d'
5959

6060
default['minikube']['download_path'] =
61-
'https://github.com/kubernetes/minikube/releases/download/v1.30.1/minikube-linux-amd64'
61+
'https://github.com/kubernetes/minikube/releases/download/v1.36.0/minikube-linux-amd64'
6262
default['minikube']['sha256'] =
63-
'e53d9e8c31f4c5f683182f5323d3527aa0725f713945c6d081cf71aa548ab388'
63+
'cddeab5ab86ab98e4900afac9d62384dae0941498dfbe712ae0c8868250bc3d7'
6464

6565
default['opm']['download_path'] =
6666
'https://github.com/operator-framework/operator-registry/releases/download/v1.26.4/linux-amd64-opm'
@@ -73,19 +73,19 @@
7373
'8a94b84542d21b8785847f4cccc8a6da4c7be5e16d4b1a2d0a5f7ec5532faec0'
7474

7575
default['skaffold']['download_path'] =
76-
'https://storage.googleapis.com/skaffold/releases/v2.0.4/skaffold-linux-amd64'
76+
'https://storage.googleapis.com/skaffold/releases/v2.16.1/skaffold-linux-amd64'
7777
default['skaffold']['sha256'] =
78-
'f1c54245b97073f39b209dd4b769802701c9901ceaa95774e7507d95bbd1d4c0'
78+
'1cbeea85aa14ba603dbc2bbdfa7bfde5644d7988beed0fdc0fd1c67298d4cf67'
7979

8080
default['sops']['download_path'] =
81-
'https://github.com/mozilla/sops/releases/download/3.3.1/sops-3.3.1.linux'
81+
'https://github.com/mozilla/sops/releases/download/v3.10.2/sops-v3.10.2.linux.amd64'
8282
default['sops']['sha256'] =
83-
'6eacdd01b68fd140eb71bbca233bea897cccb75dbf9e00a02e648b2f9a8a6939'
83+
'79b0f844237bd4b0446e4dc884dbc1765fc7dedc3968f743d5949c6f2e701739'
8484

8585
default['trivy']['download_path'] =
86-
'https://github.com/aquasecurity/trivy/releases/download/v0.39.0/trivy_0.39.0_Linux-64bit.tar.gz'
86+
'https://github.com/aquasecurity/trivy/releases/download/v0.64.1/trivy_0.64.1_Linux-64bit.tar.gz'
8787
default['trivy']['sha256'] =
88-
'77cfe88b6b803909982e2dd41149c042fd9e6a58e1f55103f27e7bab2d2fb6d2'
88+
'1a09d86667b3885a8783d1877c9abc8061b2b4e9b403941b22cbd82f10d275a8'
8989

9090
default['yq']['download_path'] =
9191
'https://github.com/mikefarah/yq/releases/download/v4.30.8/yq_linux_amd64'

tools/chef/cookbooks/px_dev_extras/attributes/mac_os_x.rb

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,19 +34,19 @@
3434
'869f4d8acaa1feb11ce76b2204c5476b8a04d9451216adde6b18e2ef2f978794'
3535

3636
default['gh']['download_path'] =
37-
'https://github.com/cli/cli/releases/download/v2.26.1/gh_2.26.1_macOS_amd64.tar.gz'
37+
'https://github.com/cli/cli/releases/download/v2.76.1/gh_2.76.1_macOS_amd64.tar.gz'
3838
default['gh']['sha256'] =
39-
'ef398ece1f31d033df6374458f7a87500ccdbdc9964170db04b6a5f707632417'
39+
'0019dfc4b32d63c1392aa264aed2253c1e0c2fb09216f8e2cc269bbfb8bb49b5'
4040

4141
default['helm']['download_path'] =
4242
'https://get.helm.sh/helm-v3.11.3-darwin-amd64.tar.gz'
4343
default['helm']['sha256'] =
4444
'9d029df37664b50e427442a600e4e065fa75fd74dac996c831ac68359654b2c4'
4545

4646
default['kubectl']['download_path'] =
47-
'https://storage.googleapis.com/kubernetes-release/release/v1.26.0/bin/darwin/amd64/kubectl'
47+
'https://dl.k8s.io/release/v1.33.3/bin/darwin/amd64/kubectl'
4848
default['kubectl']['sha256'] =
49-
'be9dc0782a7b257d9cfd66b76f91081e80f57742f61e12cd29068b213ee48abc'
49+
'9652b55a58e84454196a7b9009f6d990d3961e2bd4bd03f64111d959282b46b1'
5050

5151
default['kustomize']['download_path'] =
5252
'https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2Fv5.0.3/kustomize_v5.0.3_darwin_amd64.tar.gz'
@@ -59,9 +59,9 @@
5959
'eaf2792d9731c911da671a6145eebd5ba136c20446adb542e7b1463ffe868388'
6060

6161
default['minikube']['download_path'] =
62-
'https://github.com/kubernetes/minikube/releases/download/v1.30.1/minikube-darwin-amd64'
62+
'https://github.com/kubernetes/minikube/releases/download/v1.36.0/minikube-darwin-amd64'
6363
default['minikube']['sha256'] =
64-
'b5938a8772c5565b5d0b795938c367c5190bf65bb51fc55fb2417cb4e1d04ef1'
64+
'a7e3da0db4041b2f845ca37af592424a9cbe34087ac922220b1e3abc4e1976ea'
6565

6666
default['opm']['download_path'] =
6767
'https://github.com/operator-framework/operator-registry/releases/download/v1.26.4/darwin-amd64-opm'
@@ -74,19 +74,19 @@
7474
'8666031111138e2e79ff7d1e42888b23b793b856bc2d9c9dccbb1e2d2cccb5cf'
7575

7676
default['skaffold']['download_path'] =
77-
'https://storage.googleapis.com/skaffold/releases/v2.0.4/skaffold-darwin-amd64'
77+
'https://storage.googleapis.com/skaffold/releases/v2.16.1/skaffold-darwin-amd64'
7878
default['skaffold']['sha256'] =
79-
'd0956712db4d2dd8084ffe297bf645ec92506b87db5f61c0f5e24c7fd99bf0a3'
79+
'ed4c6cd0c82f48908db6bc1210b2f609bb5672b340ad1fbaa092ed2c6acedeb5'
8080

8181
default['sops']['download_path'] =
82-
'https://github.com/mozilla/sops/releases/download/3.3.1/sops-3.3.1.darwin'
82+
'https://github.com/mozilla/sops/releases/download/v3.10.2/sops-v3.10.2.darwin.amd64'
8383
default['sops']['sha256'] =
84-
'09bb5920ae609bdf041b74843e2d8211a7059847b21729fadfbd3c3e33e67d26'
84+
'dece9b0131af5ced0f8c278a53c0cf06a4f0d1d70a177c0979f6d111654397ce'
8585

8686
default['trivy']['download_path'] =
87-
'https://github.com/aquasecurity/trivy/releases/download/v0.39.0/trivy_0.39.0_macOS-64bit.tar.gz'
87+
'https://github.com/aquasecurity/trivy/releases/download/v0.64.1/trivy_0.64.1_macOS-64bit.tar.gz'
8888
default['trivy']['sha256'] =
89-
'e0e6831395310452a65cae8dcb142fb743a05b27b0698177e8fad93b24490e19'
89+
'107a874b41c1f0a48849f859b756f500d8be06f2d2b8956a046a97ae38088bf6'
9090

9191
default['yq']['download_path'] =
9292
'https://github.com/mikefarah/yq/releases/download/v4.30.8/yq_darwin_amd64'

0 commit comments

Comments
 (0)