Skip to content

Commit f277d27

Browse files
authored
Merge pull request #33 from swastik959/namespace
correct namespace for compliance operator
2 parents 7e14a65 + eb90f35 commit f277d27

6 files changed

Lines changed: 15 additions & 15 deletions

File tree

chart/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ annotations:
33
catalog.cattle.io/certified: rancher
44
catalog.cattle.io/display-name: Rancher Compliance
55
catalog.cattle.io/kube-version: '>= 1.31.0-0 < 1.34.0-0'
6-
catalog.cattle.io/namespace: rancher-compliance-system
6+
catalog.cattle.io/namespace: compliance-operator-system
77
catalog.cattle.io/os: linux
88
catalog.cattle.io/permits-os: linux,windows
99
catalog.cattle.io/provides-gvr: compliance.cattle.io.clusterscans/v1

chart/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ The compliance-operator enables running security scans on a kubernetes cluster a
55
# Installation
66

77
```
8-
helm install rancher-compliance ./ --create-namespace -n rancher-compliance-system
8+
helm install rancher-compliance ./ --create-namespace -n compliance-operator-system
99
```

chart/templates/_helpers.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{{/* Ensure namespace is set the same everywhere */}}
22
{{- define "app.namespace" -}}
3-
{{- .Release.Namespace | default "rancher-compliance-system" -}}
3+
{{- .Release.Namespace | default "compliance-operator-system" -}}
44
{{- end -}}
55

66
{{- define "system_default_registry" -}}

hack/e2e

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ function pull_image() {
3434
}
3535

3636
function dump_logs() {
37-
${KUBECTL} get pods -n rancher-compliance-system --show-labels
37+
${KUBECTL} get pods -n compliance-operator-system --show-labels
3838
echo "RUNNER LOGS:"
39-
${KUBECTL} logs -n rancher-compliance-system -l app.kubernetes.io/instance=security-scan-runner-k3s-e2e-scan || true
39+
${KUBECTL} logs -n compliance-operator-system -l app.kubernetes.io/instance=security-scan-runner-k3s-e2e-scan || true
4040
echo "SONOBUOY LOGS (rancher-kube-bench):"
41-
${KUBECTL} logs -n rancher-compliance-system -l component=sonobuoy -c rancher-kube-bench || true
41+
${KUBECTL} logs -n compliance-operator-system -l component=sonobuoy -c rancher-kube-bench || true
4242
echo "SONOBUOY LOGS (sonobuoy-worker):"
43-
${KUBECTL} logs -n rancher-compliance-system -l component=sonobuoy -c sonobuoy-worker || true
43+
${KUBECTL} logs -n compliance-operator-system -l component=sonobuoy -c sonobuoy-worker || true
4444
}
4545

4646
echo "Running E2E tests"
@@ -72,7 +72,7 @@ ${KUBECTL} wait --timeout=60s --for=condition=ready -n kube-system pod -l k8s-ap
7272
echo "> Deploying compliance-operator"
7373
${KUBECTL} apply -f ./crds
7474

75-
${HELM} install --create-namespace --namespace rancher-compliance-system \
75+
${HELM} install --create-namespace --namespace compliance-operator-system \
7676
--set "image.operator.repository=${IMAGE%%:*}" \
7777
--set "image.operator.tag=${IMAGE#*:}" \
7878
--set "debug=true" \
@@ -82,7 +82,7 @@ echo "> Wait for compliance-operator to be ready"
8282
# Can't kubectl wait before the deployment schedules the pod, so
8383
# wait 10 seconds for that to happen first.
8484
sleep 10
85-
${KUBECTL} wait --for=condition=ready -n rancher-compliance-system pod -l compliance.cattle.io/operator=compliance-operator --timeout=30s
85+
${KUBECTL} wait --for=condition=ready -n compliance-operator-system pod -l compliance.cattle.io/operator=compliance-operator --timeout=30s
8686

8787
echo "> Create ClusterScan"
8888
${KUBECTL} apply -f tests/k3s-bench-test.yaml

pkg/apis/compliance.cattle.io/v1/types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const (
1313
ClusterProviderAKS = "aks"
1414
ClusterProviderK3s = "k3s"
1515

16-
ClusterScanNS = "rancher-compliance-system"
16+
ClusterScanNS = "compliance-operator-system"
1717
ClusterScanSA = "compliance-scan-serviceaccount"
1818
ClusterScanConfigMap = "compliance-config-cm"
1919
ClusterScanPluginsConfigMap = "compliance-plugins-cm"

tests/k3s-bench-test.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: compliance.cattle.io/v1
22
kind: ClusterScan
33
metadata:
44
name: k3s-e2e-scan
5-
namespace: rancher-compliance-system
5+
namespace: compliance-operator-system
66
spec:
77
scanProfileName: k3s-e2e-profile
88
scoreWarning: pass
@@ -11,26 +11,26 @@ apiVersion: compliance.cattle.io/v1
1111
kind: ClusterScanProfile
1212
metadata:
1313
name: k3s-e2e-profile
14-
namespace: rancher-compliance-system
14+
namespace: compliance-operator-system
1515
spec:
1616
benchmarkVersion: sample-ssb-1.0
1717
---
1818
apiVersion: compliance.cattle.io/v1
1919
kind: ClusterScanBenchmark
2020
metadata:
2121
name: sample-ssb-1.0
22-
namespace: rancher-compliance-system
22+
namespace: compliance-operator-system
2323
spec:
2424
customBenchmarkConfigMapName: sample-ssb-1.0
25-
customBenchmarkConfigMapNamespace: rancher-compliance-system
25+
customBenchmarkConfigMapNamespace: compliance-operator-system
2626
minKubernetesVersion: '1.30.0'
2727
maxKubernetesVersion: '1.36.0'
2828
---
2929
apiVersion: v1
3030
kind: ConfigMap
3131
metadata:
3232
name: sample-ssb-1.0
33-
namespace: rancher-compliance-system
33+
namespace: compliance-operator-system
3434
data:
3535
config.yaml: |
3636
## Version-specific settings that override the values in cfg/config.yaml

0 commit comments

Comments
 (0)