aboutsummaryrefslogtreecommitdiffstats
path: root/kud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'kud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml')
-rwxr-xr-xkud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml31
1 files changed, 31 insertions, 0 deletions
diff --git a/kud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml b/kud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml
new file mode 100755
index 00000000..3d26f467
--- /dev/null
+++ b/kud/tests/vnfs/comp-app/collection/app2/helm/prometheus-operator/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml
@@ -0,0 +1,31 @@
+{{- if and .Values.prometheusOperator.admissionWebhooks.enabled }}
+apiVersion: admissionregistration.k8s.io/v1beta1
+kind: ValidatingWebhookConfiguration
+metadata:
+ name: {{ template "prometheus-operator.fullname" . }}-admission
+ labels:
+ app: {{ template "prometheus-operator.name" $ }}-admission
+{{- include "prometheus-operator.labels" $ | indent 4 }}
+webhooks:
+ - name: prometheusrulemutate.monitoring.coreos.com
+ {{- if .Values.prometheusOperator.admissionWebhooks.patch.enabled }}
+ failurePolicy: Ignore
+ {{- else }}
+ failurePolicy: {{ .Values.prometheusOperator.admissionWebhooks.failurePolicy }}
+ {{- end }}
+ rules:
+ - apiGroups:
+ - monitoring.coreos.com
+ apiVersions:
+ - "*"
+ resources:
+ - prometheusrules
+ operations:
+ - CREATE
+ - UPDATE
+ clientConfig:
+ service:
+ namespace: {{ template "prometheus-operator.namespace" . }}
+ name: {{ template "prometheus-operator.operator.fullname" $ }}
+ path: /admission-prometheusrules/validate
+{{- end }}