diff --git a/helm/agents/argo-rollouts/templates/_helpers.tpl b/helm/agents/argo-rollouts/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/argo-rollouts/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/argo-rollouts/templates/agent.yaml b/helm/agents/argo-rollouts/templates/agent.yaml index 466e824758..033d9e5e04 100644 --- a/helm/agents/argo-rollouts/templates/agent.yaml +++ b/helm/agents/argo-rollouts/templates/agent.yaml @@ -187,9 +187,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/argo-rollouts/values.yaml b/helm/agents/argo-rollouts/values.yaml index b0f51d9951..8ffcecbc8b 100644 --- a/helm/agents/argo-rollouts/values.yaml +++ b/helm/agents/argo-rollouts/values.yaml @@ -16,3 +16,7 @@ resources: compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/cilium-debug/templates/_helpers.tpl b/helm/agents/cilium-debug/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/cilium-debug/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/cilium-debug/templates/agent.yaml b/helm/agents/cilium-debug/templates/agent.yaml index 4826e15b8f..fe205e2bf6 100644 --- a/helm/agents/cilium-debug/templates/agent.yaml +++ b/helm/agents/cilium-debug/templates/agent.yaml @@ -160,9 +160,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/cilium-debug/values.yaml b/helm/agents/cilium-debug/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/cilium-debug/values.yaml +++ b/helm/agents/cilium-debug/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/cilium-manager/templates/_helpers.tpl b/helm/agents/cilium-manager/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/cilium-manager/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/cilium-manager/templates/agent.yaml b/helm/agents/cilium-manager/templates/agent.yaml index 9013aff50b..27284c6bb6 100644 --- a/helm/agents/cilium-manager/templates/agent.yaml +++ b/helm/agents/cilium-manager/templates/agent.yaml @@ -432,9 +432,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/cilium-manager/values.yaml b/helm/agents/cilium-manager/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/cilium-manager/values.yaml +++ b/helm/agents/cilium-manager/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/cilium-policy/templates/_helpers.tpl b/helm/agents/cilium-policy/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/cilium-policy/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/cilium-policy/templates/agent.yaml b/helm/agents/cilium-policy/templates/agent.yaml index 5c9d029147..9af38cc240 100644 --- a/helm/agents/cilium-policy/templates/agent.yaml +++ b/helm/agents/cilium-policy/templates/agent.yaml @@ -524,9 +524,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/cilium-policy/values.yaml b/helm/agents/cilium-policy/values.yaml index b0f51d9951..8ffcecbc8b 100644 --- a/helm/agents/cilium-policy/values.yaml +++ b/helm/agents/cilium-policy/values.yaml @@ -16,3 +16,7 @@ resources: compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/helm/templates/_helpers.tpl b/helm/agents/helm/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/helm/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/helm/templates/agent.yaml b/helm/agents/helm/templates/agent.yaml index 2b5dab71ea..0a7882798c 100644 --- a/helm/agents/helm/templates/agent.yaml +++ b/helm/agents/helm/templates/agent.yaml @@ -179,9 +179,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/helm/values.yaml b/helm/agents/helm/values.yaml index b0f51d9951..8ffcecbc8b 100644 --- a/helm/agents/helm/values.yaml +++ b/helm/agents/helm/values.yaml @@ -16,3 +16,7 @@ resources: compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/istio/templates/_helpers.tpl b/helm/agents/istio/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/istio/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/istio/templates/agent.yaml b/helm/agents/istio/templates/agent.yaml index e6311e8e8d..4e0b9d775e 100644 --- a/helm/agents/istio/templates/agent.yaml +++ b/helm/agents/istio/templates/agent.yaml @@ -232,9 +232,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/istio/values.yaml b/helm/agents/istio/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/istio/values.yaml +++ b/helm/agents/istio/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/k8s/templates/_helpers.tpl b/helm/agents/k8s/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/k8s/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/k8s/templates/agent.yaml b/helm/agents/k8s/templates/agent.yaml index fc7660e70a..343802569c 100644 --- a/helm/agents/k8s/templates/agent.yaml +++ b/helm/agents/k8s/templates/agent.yaml @@ -150,9 +150,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/k8s/values.yaml b/helm/agents/k8s/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/k8s/values.yaml +++ b/helm/agents/k8s/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/kgateway/templates/_helpers.tpl b/helm/agents/kgateway/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/kgateway/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/kgateway/templates/agent.yaml b/helm/agents/kgateway/templates/agent.yaml index c103468532..523cb40413 100644 --- a/helm/agents/kgateway/templates/agent.yaml +++ b/helm/agents/kgateway/templates/agent.yaml @@ -314,9 +314,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/kgateway/values.yaml b/helm/agents/kgateway/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/kgateway/values.yaml +++ b/helm/agents/kgateway/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/observability/templates/_helpers.tpl b/helm/agents/observability/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/observability/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/observability/templates/agent.yaml b/helm/agents/observability/templates/agent.yaml index 8d7a05a101..6132ae2d7e 100644 --- a/helm/agents/observability/templates/agent.yaml +++ b/helm/agents/observability/templates/agent.yaml @@ -166,9 +166,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/observability/values.yaml b/helm/agents/observability/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/observability/values.yaml +++ b/helm/agents/observability/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {} diff --git a/helm/agents/promql/templates/_helpers.tpl b/helm/agents/promql/templates/_helpers.tpl new file mode 100644 index 0000000000..683d0a2303 --- /dev/null +++ b/helm/agents/promql/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{- define "agent.deploymentSpec" -}} +{{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} +imagePullSecrets: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.podSecurityContext }} +podSecurityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +{{- with .Values.securityContext }} +securityContext: + {{- toYaml . | nindent 2 }} +{{- end }} +resources: + {{- toYaml .Values.resources | nindent 2 }} +{{- end }} diff --git a/helm/agents/promql/templates/agent.yaml b/helm/agents/promql/templates/agent.yaml index 17bd93fa9e..e48f0dcb1e 100644 --- a/helm/agents/promql/templates/agent.yaml +++ b/helm/agents/promql/templates/agent.yaml @@ -213,10 +213,4 @@ spec: compaction: {{- toYaml .Values.compaction | nindent 8 }} {{- end }} deployment: - {{- with coalesce (empty .Values.imagePullSecrets | ternary nil .Values.imagePullSecrets) .Values.global.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 8 }} - \ No newline at end of file + {{- include "agent.deploymentSpec" . | nindent 6 }} diff --git a/helm/agents/promql/values.yaml b/helm/agents/promql/values.yaml index 1cfd5eeaf3..7de147c565 100644 --- a/helm/agents/promql/values.yaml +++ b/helm/agents/promql/values.yaml @@ -15,3 +15,7 @@ resources: memory: 1Gi compaction: {} + +podSecurityContext: {} + +securityContext: {}