Skip to content

Commit

Permalink
Skip the secrets and volume mounts in the allocator pod when (#2277)
Browse files Browse the repository at this point in the history
they aren't needed (e.g. TLS or mTLS is disabled).
  • Loading branch information
roberthbailey authored Sep 29, 2021
1 parent 50ef328 commit 466bc3b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions install/helm/agones/templates/service/allocation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -117,13 +117,17 @@ spec:
{{ toYaml .Values.agones.allocator.tolerations | indent 8 }}
{{- end }}
serviceAccountName: {{ $.Values.agones.serviceaccount.allocator.name }}
{{- if eq .Values.agones.allocator.disableTLS false }}
volumes:
- name: tls
secret:
secretName: allocator-tls
{{- if eq .Values.agones.allocator.disableMTLS false }}
- name: client-ca
secret:
secretName: allocator-client-ca
{{- end }}
{{- end }}
containers:
- name: agones-allocator
image: "{{ .Values.agones.image.registry }}/{{ .Values.agones.image.allocator.name}}:{{ default .Values.agones.image.tag .Values.agones.image.allocator.tag }}"
Expand Down Expand Up @@ -197,13 +201,17 @@ spec:
- name: {{ .Values.agones.allocator.service.grpc.portName }}
containerPort: {{ .Values.agones.allocator.service.grpc.targetPort }}
{{- end }}
{{- if eq .Values.agones.allocator.disableTLS false }}
volumeMounts:
- mountPath: /home/allocator/tls
name: tls
readOnly: true
{{- if eq .Values.agones.allocator.disableMTLS false }}
- mountPath: /home/allocator/client-ca
name: client-ca
readOnly: true
{{- end }}
{{- end }}
{{- if .Values.agones.allocator.resources }}
resources:
{{ toYaml .Values.agones.allocator.resources | indent 10 }}
Expand Down

0 comments on commit 466bc3b

Please sign in to comment.