charts/modem-stats/templates/deployment.yaml
Jeff Billimek efd1200716
adding pod annotations to modem-stats chart (#77)
Signed-off-by: Jeff Billimek <jeff@billimek.com>
2019-10-07 13:38:34 -04:00

48 lines
1.4 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ template "modem-stats.fullname" . }}
labels:
app: {{ template "modem-stats.name" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- if .Values.podAnnotations }}
annotations:
{{- range $key, $value := .Values.podAnnotations }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- end }}
spec:
selector:
matchLabels:
app: {{ template "modem-stats.name" . }}
release: {{ .Release.Name }}
replicas: {{ default 1 .Values.replicas }}
template:
metadata:
labels:
app: {{ template "modem-stats.name" . }}
release: {{ .Release.Name }}
spec:
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
resources:
{{ toYaml .Values.resources | indent 12 }}
volumeMounts:
- name: {{ template "modem-stats.name" . }}
mountPath: /src/config.ini
subPath: config.ini
{{- if .Values.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nodeSelector | indent 8 }}
{{- end }}
volumes:
- name: {{ template "modem-stats.name" . }}
configMap:
name: {{ template "modem-stats.fullname" . }}
items:
- key: config.ini
path: config.ini