Skip to content

Commit

Permalink
admission: remove init containers
Browse files Browse the repository at this point in the history
  • Loading branch information
mingming.zhou committed Aug 24, 2022
1 parent d925b9e commit 9d3e4d8
Showing 1 changed file with 8 additions and 18 deletions.
26 changes: 8 additions & 18 deletions helm/hwameistor/templates/admission-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,14 @@ spec:
app: hwameistor-admission-controller
spec:
serviceAccountName: hwameistor-admin
initContainers:
- image: {{ .Values.hwameistorImageRegistry}}/{{ .Values.admission.selfSigned.imageRepository}}:{{ .Values.admission.selfSigned.tag}}
containers:
- name: server
args:
- --cert-dir=/etc/webhook/certs
- --tls-private-key-file=tls.key
- --tls-cert-file=tls.crt
image: {{ .Values.hwameistorImageRegistry}}/{{ .Values.admission.imageRepository}}:{{ template "hwameistor.admissionImageTag" . }}
imagePullPolicy: IfNotPresent
name: self-signed
resources:
{{- toYaml .Values.admission.resources | nindent 12 }}
env:
- name: WEBHOOK_NAMESPACE
value: {{ .Release.Namespace}}
Expand All @@ -33,17 +35,6 @@ spec:
value: hwameistor-admission-controller
- name: MUTATE_PATH
value: /mutate
volumeMounts:
- mountPath: /etc/webhook/certs
name: admission-controller-tls-certs
containers:
- name: server
args:
- --cert-dir=/etc/webhook/certs
- --tls-private-key-file=tls.key
- --tls-cert-file=tls.crt
image: {{ .Values.hwameistorImageRegistry}}/{{ .Values.admission.imageRepository}}:{{ template "hwameistor.admissionImageTag" . }}
imagePullPolicy: IfNotPresent
resources:
{{- toYaml .Values.admission.resources | nindent 12 }}
ports:
Expand All @@ -52,7 +43,6 @@ spec:
volumeMounts:
- name: admission-controller-tls-certs
mountPath: /etc/webhook/certs
readOnly: true
volumes:
- name: admission-controller-tls-certs
emptyDir: {}
Expand All @@ -74,4 +64,4 @@ spec:
apiVersion: admissionregistration.k8s.io/v1
kind: MutatingWebhookConfiguration
metadata:
name: hwameistor-admission-mutate
name: hwameistor-admission-mutate

0 comments on commit 9d3e4d8

Please sign in to comment.