Skip to content

Commit 1e372fa

Browse files
authored
Merge pull request #531 from vardhaman22/v1.2/add-validation-templates
[release/v1.2] added validate-install-crd template
2 parents c88d47f + f65d609 commit 1e372fa

File tree

4 files changed

+1615
-96
lines changed

4 files changed

+1615
-96
lines changed

Diff for: chart/templates/validate-install-crd.yaml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#{{- if gt (len (lookup "rbac.authorization.k8s.io/v1" "ClusterRole" "" "")) 0 -}}
2+
# {{- $found := dict -}}
3+
# {{- set $found "cis.cattle.io/v1/ClusterScan" false -}}
4+
# {{- set $found "cis.cattle.io/v1/ClusterScanBenchmark" false -}}
5+
# {{- set $found "cis.cattle.io/v1/ClusterScanProfile" false -}}
6+
# {{- set $found "cis.cattle.io/v1/ClusterScanReport" false -}}
7+
# {{- range .Capabilities.APIVersions -}}
8+
# {{- if hasKey $found (toString .) -}}
9+
# {{- set $found (toString .) true -}}
10+
# {{- end -}}
11+
# {{- end -}}
12+
# {{- range $_, $exists := $found -}}
13+
# {{- if (eq $exists false) -}}
14+
# {{- required "Required CRDs are missing. Please install the corresponding CRD chart before installing this chart." "" -}}
15+
# {{- end -}}
16+
# {{- end -}}
17+
#{{- end -}}

Diff for: chart/values.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
image:
66
cisoperator:
77
repository: rancher/cis-operator
8-
tag: v1.2.1
8+
tag: v1.2.2
99
securityScan:
1010
repository: rancher/security-scan
1111
tag: v0.4.1

Diff for: go.mod

+20-13
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,29 @@ go 1.22.0
44

55
toolchain go1.22.10
66

7+
// pinned these to keep deps in sync with rancher
8+
replace (
9+
k8s.io/api => k8s.io/api v0.30.7
10+
k8s.io/apimachinery => k8s.io/apimachinery v0.30.7
11+
k8s.io/client-go => k8s.io/client-go v0.30.7
12+
)
13+
714
require (
815
github.com/blang/semver v3.5.1+incompatible
916
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.74.0
1017
github.com/prometheus-operator/prometheus-operator/pkg/client v0.74.0
1118
github.com/prometheus/client_golang v1.20.5
1219
github.com/rancher/kubernetes-provider-detector v0.1.5
1320
github.com/rancher/lasso v0.0.0-20240828170735-d79536cac289
14-
github.com/rancher/security-scan v0.4.0
21+
github.com/rancher/security-scan v0.4.1
1522
github.com/robfig/cron v1.2.0
1623
github.com/sirupsen/logrus v1.9.3
1724
github.com/urfave/cli v1.22.16
1825
golang.org/x/crypto/x509roots/fallback v0.0.0-20231030152948-74c2ba9521f1
19-
k8s.io/api v0.30.7
26+
k8s.io/api v0.31.2
2027
k8s.io/apiextensions-apiserver v0.30.7
21-
k8s.io/apimachinery v0.30.7
22-
k8s.io/client-go v0.30.7
28+
k8s.io/apimachinery v0.31.2
29+
k8s.io/client-go v0.31.2
2330
)
2431

2532
require (
@@ -28,10 +35,10 @@ require (
2835
)
2936

3037
require (
31-
github.com/aquasecurity/kube-bench v0.9.1 // indirect
32-
github.com/aws/aws-sdk-go-v2 v1.31.0 // indirect
33-
github.com/aws/aws-sdk-go-v2/service/securityhub v1.53.3 // indirect
34-
github.com/aws/smithy-go v1.21.0 // indirect
38+
github.com/aquasecurity/kube-bench v0.9.2 // indirect
39+
github.com/aws/aws-sdk-go-v2 v1.32.4 // indirect
40+
github.com/aws/aws-sdk-go-v2/service/securityhub v1.54.6 // indirect
41+
github.com/aws/smithy-go v1.22.0 // indirect
3542
github.com/beorn7/perks v1.0.1 // indirect
3643
github.com/cespare/xxhash/v2 v2.3.0 // indirect
3744
github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect
@@ -40,12 +47,12 @@ require (
4047
github.com/evanphx/json-patch v5.9.0+incompatible // indirect
4148
github.com/fsnotify/fsnotify v1.7.0 // indirect
4249
github.com/ghodss/yaml v1.0.0 // indirect
43-
github.com/go-logr/logr v1.4.1 // indirect
50+
github.com/go-logr/logr v1.4.2 // indirect
4451
github.com/go-openapi/jsonpointer v0.21.0 // indirect
4552
github.com/go-openapi/jsonreference v0.21.0 // indirect
4653
github.com/go-openapi/swag v0.23.0 // indirect
4754
github.com/gogo/protobuf v1.3.2 // indirect
48-
github.com/golang/glog v1.2.2 // indirect
55+
github.com/golang/glog v1.2.3 // indirect
4956
github.com/golang/protobuf v1.5.4 // indirect
5057
github.com/google/gnostic-models v0.6.8 // indirect
5158
github.com/google/go-cmp v0.6.0 // indirect
@@ -83,7 +90,7 @@ require (
8390
golang.org/x/net v0.26.0 // indirect
8491
golang.org/x/oauth2 v0.21.0 // indirect
8592
golang.org/x/sync v0.7.0 // indirect
86-
golang.org/x/sys v0.22.0 // indirect
93+
golang.org/x/sys v0.25.0 // indirect
8794
golang.org/x/term v0.21.0 // indirect
8895
golang.org/x/text v0.16.0 // indirect
8996
golang.org/x/time v0.5.0 // indirect
@@ -95,9 +102,9 @@ require (
95102
gopkg.in/yaml.v3 v3.0.1 // indirect
96103
k8s.io/code-generator v0.30.7 // indirect
97104
k8s.io/gengo v0.0.0-20240228010128-51d4e06bde70 // indirect
98-
k8s.io/klog/v2 v2.120.1 // indirect
105+
k8s.io/klog/v2 v2.130.1 // indirect
99106
k8s.io/kube-openapi v0.0.0-20240322212309-b815d8309940 // indirect
100-
k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0 // indirect
107+
k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 // indirect
101108
sigs.k8s.io/controller-runtime v0.17.2 // indirect
102109
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
103110
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect

0 commit comments

Comments
 (0)