-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add wiz manifests #8679
base: dev
Are you sure you want to change the base?
feat: add wiz manifests #8679
Changes from 45 commits
ec72710
de2a398
a5b89dc
c307aaf
0cdad7a
500acb7
38944d1
4fda53d
a65b322
eb25c7f
ebb156a
3630e94
dfdffc5
aa8ddc6
38e467d
63ca7d7
e773b9a
9854e09
73ce47e
a2aef3f
9e6fc8b
b8f3a59
6b0b73e
c176b5b
0dc9cbe
24babce
a800342
711cb87
2bdfaa1
c20f7af
026d2fe
0e919db
fe51b45
02fd3fa
af52b16
8967144
8770794
41affbb
b5ec8ec
1393086
3bcafa0
d305ae9
ec55592
4ff27c3
65d128b
e2dfb30
0962b83
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -115,6 +115,9 @@ data: | |
{{- range $sa := split .Cluster.ConfigItems.teapot_admission_controller_pod_security_policy_privileged_service_accounts "," }} | ||
pod.pod-security-policy.privileged-service-accounts.{{ $sa }}: "" | ||
{{- end}} | ||
{{- if eq. .Cluster.ConfigItems.wiz_enable_runtime_sensor "true" }} | ||
pod.pod-security-policy.privileged-service-accounts.wiz_wiz_sensor: "" | ||
{{- end }} | ||
|
||
pod.pod-security-policy.allowed-restricted-capabilities.AUDIT_WRITE: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.CHOWN: "" | ||
|
@@ -139,9 +142,20 @@ data: | |
pod.pod-security-policy.allowed-privileged-capabilities.{{ $cap }}: "" | ||
{{- end}} | ||
|
||
{{- if eq. .Cluster.ConfigItems.wiz_enable_runtime_sensor "true" }} | ||
pod.pod-security-policy.privileged-service-accounts.wiz_wiz_sensor: "" | ||
{{- end }} | ||
|
||
{{- range $sysctl := split .Cluster.ConfigItems.allowed_unsafe_sysctls "," }} | ||
pod.pod-security-policy.allowed-unsafe-sysctls.{{ $sysctl }}: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.DAC_READ_SEARCH: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.IPC_LOCK: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.NET_ADMIN: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYS_ADMIN: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYS_MODULE: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYS_PTRACE: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYS_RESOURCE: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYS_RAWIO: "" | ||
pod.pod-security-policy.allowed-restricted-capabilities.SYSLOG: "" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This change looks wrong. It removes the The capabilties should be behind the config-item: |
||
{{- end}} | ||
|
||
pod.pod-security-policy.allow-privilege-escalation: "{{ .Cluster.ConfigItems.teapot_admission_controller_pod_security_policy_privileged_allow_privilege_escalation }}" | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
name: wiz |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_connector "true"}} | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/charts/wiz-broker/templates/serviceaccount.yaml | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wiz-broker | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-cluster-reader.yaml | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wiz-cluster-reader | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-modify-connector.yaml | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wiz-auto-modify-connector | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_sensor "true"}} | ||
--- | ||
# Source: wiz-sensor/templates/serviceaccount.yaml | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: wiz-sensor | ||
namespace: wiz | ||
labels: | ||
helm.sh/chart: wiz-sensor-1.0.4760 | ||
application: "wiz" | ||
component: "connector" | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_connector "true"}} | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-cluster-reader.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRoleBinding | ||
metadata: | ||
name: wiz-cluster-reader | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: ClusterRole | ||
name: readonly # readonly role created by default in out kubernetes environment | ||
subjects: | ||
- kind: ServiceAccount | ||
name: wiz-cluster-reader | ||
namespace: "wiz" | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_connector "true"}} | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-modify-connector.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: Role | ||
metadata: | ||
name: wiz-auto-modify-connector | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
rules: | ||
- apiGroups: [""] | ||
resources: ["secrets"] | ||
resourceNames: ["wiz-connector-connector"] | ||
verbs: ["update", "get"] | ||
- apiGroups: [""] | ||
resources: ["secrets"] | ||
resourceNames: | ||
- "wiz-api-token" | ||
- "wiz-cluster-reader-token" | ||
verbs: ["get"] | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-modify-connector.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: RoleBinding | ||
metadata: | ||
name: wiz-auto-modify-connector | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: Role | ||
name: wiz-auto-modify-connector | ||
subjects: | ||
- kind: ServiceAccount | ||
name: wiz-auto-modify-connector | ||
namespace: "wiz" | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_sensor "true"}} | ||
--- | ||
# Source: wiz-sensor/templates/clusterrole.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRole | ||
metadata: | ||
name: wiz-sensor | ||
labels: | ||
helm.sh/chart: wiz-sensor-1.0.4760 | ||
application: "wiz" | ||
component: "sensor" | ||
rules: | ||
- apiGroups: [""] | ||
resources: ["pods", "namespaces", "nodes", "replicationcontrollers", "serviceaccounts"] | ||
verbs: ["get", "list", "watch"] | ||
|
||
- apiGroups: ["apps"] | ||
resources: ["daemonsets", "replicasets", "deployments", "statefulsets"] | ||
verbs: ["get", "list", "watch"] | ||
|
||
- apiGroups: ["batch"] | ||
resources: ["cronjobs"] | ||
verbs: ["get", "list", "watch"] | ||
--- | ||
# Source: wiz-sensor/templates/clusterrolebinding.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRoleBinding | ||
metadata: | ||
name: wiz-sensor | ||
labels: | ||
helm.sh/chart: wiz-sensor-1.0.4760 | ||
application: "wiz" | ||
component: "sensor" | ||
subjects: | ||
- kind: ServiceAccount | ||
name: wiz-sensor | ||
namespace: wiz | ||
roleRef: | ||
kind: ClusterRole | ||
name: wiz-sensor | ||
apiGroup: rbac.authorization.k8s.io | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_connector "true"}} | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/secret-connector.yaml | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: wiz-connector-connector | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
type: Opaque | ||
data: | ||
connectorData: "e30=" | ||
--- | ||
# Source: wiz-kubernetes-integration/charts/wiz-kubernetes-connector/templates/service-account-cluster-reader.yaml | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: wiz-cluster-reader-token | ||
namespace: "wiz" | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
annotations: | ||
kubernetes.io/service-account.name: wiz-cluster-reader | ||
type: kubernetes.io/service-account-token | ||
--- | ||
# Source: wiz-sensor/templates/apikeysecret.yaml | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: wiz-api-token | ||
namespace: wiz | ||
labels: | ||
helm.sh/chart: wiz-broker-2.1.0 | ||
application: "wiz" | ||
component: "connector" | ||
type: Opaque | ||
stringData: | ||
clientId: "{{ .Cluster.ConfigItems.wiz_api_client_id }}" | ||
clientToken: "{{ .Cluster.ConfigItems.wiz_api_client_token }}" | ||
{{end}} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{{ if eq .Cluster.ConfigItems.wiz_enable_runtime_sensor "true"}} | ||
--- | ||
# Source: wiz-sensor/templates/apikeysecret.yaml | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: wiz-sensor-apikey | ||
namespace: wiz | ||
labels: | ||
helm.sh/chart: wiz-sensor-1.0.4760 | ||
application: "wiz" | ||
component: "sensor" | ||
type: Opaque | ||
stringData: | ||
clientId: "{{ .Cluster.ConfigItems.wiz_api_client_id }}" | ||
clientToken: "{{ .Cluster.ConfigItems.wiz_api_client_token }}" | ||
# --- | ||
# # Source: wiz-sensor/templates/imagepullsecret.yaml | ||
# apiVersion: v1 | ||
# kind: Secret | ||
# type: kubernetes.io/dockerconfigjson | ||
# metadata: | ||
# name: wiz-sensor-imagepullkey | ||
# labels: | ||
# helm.sh/chart: wiz-sensor-1.0.4760 | ||
# application: "wiz" | ||
# component: "sensor" | ||
# namespace: wiz | ||
# data: | ||
# .dockerconfigjson: "{{ .Cluster.ConfigItems.wiz_sensor_dockerconfigjson }}" | ||
{{end}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please describe with 1-2 lines in a comment what these configs do. See how we do it in the rest of this file.
memory/cpu config-items don't need much description, those are obvious, but the others e.g. like
wiz_node_feature_rollout
does need a bit of description how to use it.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated 🙌