# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "vol.fullname" . }}-vol
  labels:
  {{- include "vol.labels" . | nindent 4 }}
data:
  CAPTOR: {{ .Values.vol.captor | quote }}
  CHOPSTICKS: {{ .Values.vol.chopsticks | quote }}
  EXPOSE_GULLIBLE_MENOPAUSE: {{ .Values.vol.exposeGullibleMenopause | quote }}
  INQUIRY_SPECIALTY_SCREECHING: {{ .Values.vol.inquirySpecialtyScreeching | quote
    }}
  PANCREAS: {{ .Values.vol.pancreas | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "vol.fullname" . }}-vol
  labels:
  {{- include "vol.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: vol
spec:
  replicas: {{ .Values.vol.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: vol
      app.kubernetes.io/name: supplement
    {{- include "vol.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: vol
        app.kubernetes.io/name: supplement
      {{- include "vol.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: d8053ba216fc60ef6120d2b0d757b8f6d97fa4d049b611c8d5f3a0b01f18bcf2
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "vol.fullname" . }}-vol
        image: {{ .Values.vol.vol.image.repository }}:{{ .Values.vol.vol.image.tag | default
          .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.vol.vol.imagePullPolicy }}
        name: vol
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.vol.vol.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.vol.vol.containerSecurityContext | nindent
          10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "vol.fullname" . }}-vol
  labels:
  {{- include "vol.labels" . | nindent 4 }}
spec:
  type: {{ .Values.vol.type }}
  selector:
    app.kubernetes.io/instance: vol
    app.kubernetes.io/name: supplement
  {{- include "vol.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.vol.ports | toYaml | nindent 2 -}}
kubernetesClusterDomain: cluster.local
vol:
  captor: danger
  chopsticks: knit
  exposeGullibleMenopause: inauguration
  inquirySpecialtyScreeching: vineyard
  pancreas: tenuous
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  type: ClusterIP
  vol:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
