# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "ceaseless.fullname" . }}-ceaseless
  labels:
  {{- include "ceaseless.labels" . | nindent 4 }}
data:
  ABDOMEN_HOUND_VANISH: {{ .Values.ceaseless.abdomenHoundVanish | quote }}
  CREATIVITY_THERMALS_SAVE: {{ .Values.ceaseless.creativityThermalsSave | quote }}
  JAM_ENCOURAGEMENT_SHY: {{ .Values.ceaseless.jamEncouragementShy | quote }}
  NOTE_CLAN_VACUUM: {{ .Values.ceaseless.noteClanVacuum | quote }}
  STANDARDIZATION_WHISPERING_WIRETAP: {{ .Values.ceaseless.standardizationWhisperingWiretap
    | quote }}
  VOLUNTEER_ENCYCLOPEDIA: {{ .Values.ceaseless.volunteerEncyclopedia | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "ceaseless.fullname" . }}-ceaseless
  labels:
  {{- include "ceaseless.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: ceaseless
spec:
  replicas: {{ .Values.ceaseless.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: ceaseless
      app.kubernetes.io/name: maggot
    {{- include "ceaseless.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: ceaseless
        app.kubernetes.io/name: maggot
      {{- include "ceaseless.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: a5ad2a744832fd74606de2534794f22ae485435da4f9814e7691f6846239a08b
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "ceaseless.fullname" . }}-ceaseless
        image: {{ .Values.ceaseless.ceaseless.image.repository }}:{{ .Values.ceaseless.ceaseless.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.ceaseless.ceaseless.imagePullPolicy }}
        name: ceaseless
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.ceaseless.ceaseless.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.ceaseless.ceaseless.containerSecurityContext
          | nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "ceaseless.fullname" . }}-ceaseless
  labels:
  {{- include "ceaseless.labels" . | nindent 4 }}
spec:
  type: {{ .Values.ceaseless.type }}
  selector:
    app.kubernetes.io/instance: ceaseless
    app.kubernetes.io/name: maggot
  {{- include "ceaseless.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.ceaseless.ports | toYaml | nindent 2 -}}
ceaseless:
  abdomenHoundVanish: gold
  ceaseless:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  creativityThermalsSave: bell
  jamEncouragementShy: insectarium
  noteClanVacuum: accomplish
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  standardizationWhisperingWiretap: bag
  type: ClusterIP
  volunteerEncyclopedia: affiliate
kubernetesClusterDomain: cluster.local
