mirror of
https://github.com/bvanroll/cicdTest.git
synced 2025-08-29 20:12:43 +00:00
NO MORE GIT SUBMODULE
This commit is contained in:
30
consul-helm/templates/connect-inject-mutatingwebhook.yaml
Normal file
30
consul-helm/templates/connect-inject-mutatingwebhook.yaml
Normal file
@@ -0,0 +1,30 @@
|
||||
# The MutatingWebhookConfiguration to enable the Connect injector.
|
||||
{{- if (or (and (ne (.Values.connectInject.enabled | toString) "-") .Values.connectInject.enabled) (and (eq (.Values.connectInject.enabled | toString) "-") .Values.global.enabled)) }}
|
||||
apiVersion: admissionregistration.k8s.io/v1beta1
|
||||
kind: MutatingWebhookConfiguration
|
||||
metadata:
|
||||
name: {{ template "consul.fullname" . }}-connect-injector-cfg
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
app: {{ template "consul.name" . }}
|
||||
chart: {{ template "consul.chart" . }}
|
||||
heritage: {{ .Release.Service }}
|
||||
release: {{ .Release.Name }}
|
||||
webhooks:
|
||||
- name: {{ template "consul.fullname" . }}-connect-injector.consul.hashicorp.com
|
||||
clientConfig:
|
||||
service:
|
||||
name: {{ template "consul.fullname" . }}-connect-injector-svc
|
||||
namespace: {{ .Release.Namespace }}
|
||||
path: "/mutate"
|
||||
caBundle: {{ .Values.connectInject.certs.caBundle | quote }}
|
||||
rules:
|
||||
- operations: [ "CREATE" ]
|
||||
apiGroups: [""]
|
||||
apiVersions: ["v1"]
|
||||
resources: ["pods"]
|
||||
{{- if .Values.connectInject.namespaceSelector }}
|
||||
namespaceSelector:
|
||||
{{ tpl .Values.connectInject.namespaceSelector . | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
Reference in New Issue
Block a user