# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "encourage.fullname" . }}-encourage
  labels:
  {{- include "encourage.labels" . | nindent 4 }}
data:
  CADDY: {{ .Values.encourage.caddy | quote }}
  CAPITULATION_MOBILE: {{ .Values.encourage.capitulationMobile | quote }}
  FLOW_TRAVEL_FEMALE: {{ .Values.encourage.flowTravelFemale | quote }}
  HAPPINESS_OVERDRAW: {{ .Values.encourage.happinessOverdraw | quote }}
  MATTER: {{ .Values.encourage.matter | quote }}
  OCTAGON: {{ .Values.encourage.octagon | quote }}
  ODOMETER_DIPLOMACY_IMPERFECT: {{ .Values.encourage.odometerDiplomacyImperfect |
    quote }}
  PARADE_PANDA: {{ .Values.encourage.paradePanda | quote }}
  PASSING_SIMPLICITY_BIDDING: {{ .Values.encourage.passingSimplicityBidding | quote
    }}
  POIGNANCE_SOLVENCY_UNEQUALED: {{ .Values.encourage.poignanceSolvencyUnequaled |
    quote }}
  SCATTER: {{ .Values.encourage.scatter | quote }}
  TABLE_NUMERACY: {{ .Values.encourage.tableNumeracy | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "encourage.fullname" . }}-encourage
  labels:
  {{- include "encourage.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: encourage
spec:
  replicas: {{ .Values.encourage.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: encourage
      app.kubernetes.io/name: increase
    {{- include "encourage.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: encourage
        app.kubernetes.io/name: increase
      {{- include "encourage.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 8244a626fed7fe36787585a33bab14f0ed153aa6dc5eda7bdc1eedb537dcec75
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "encourage.fullname" . }}-encourage
        image: {{ .Values.encourage.encourage.image.repository }}:{{ .Values.encourage.encourage.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.encourage.encourage.imagePullPolicy }}
        name: encourage
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.encourage.encourage.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.encourage.encourage.containerSecurityContext
          | nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "encourage.fullname" . }}-encourage
  labels:
  {{- include "encourage.labels" . | nindent 4 }}
spec:
  type: {{ .Values.encourage.type }}
  selector:
    app.kubernetes.io/instance: encourage
    app.kubernetes.io/name: increase
  {{- include "encourage.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.encourage.ports | toYaml | nindent 2 -}}
encourage:
  caddy: procure
  capitulationMobile: slice
  encourage:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  flowTravelFemale: irritate
  happinessOverdraw: disdain
  matter: investigator
  octagon: artichoke
  odometerDiplomacyImperfect: ape
  paradePanda: driver
  passingSimplicityBidding: piracy
  poignanceSolvencyUnequaled: recommend
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  scatter: daikon
  tableNumeracy: kettledrum
  type: ClusterIP
kubernetesClusterDomain: cluster.local
