# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "appreciate.fullname" . }}-appreciate
  labels:
  {{- include "appreciate.labels" . | nindent 4 }}
data:
  ALIAS_SOOTHE_CURTAIN: {{ .Values.appreciate.aliasSootheCurtain | quote }}
  CARTER_SATISFY: {{ .Values.appreciate.carterSatisfy | quote }}
  GLEN_DISCIPLINE_REGISTRY: {{ .Values.appreciate.glenDisciplineRegistry | quote
    }}
  RAMBUNCTIOUS_AIRBAG: {{ .Values.appreciate.rambunctiousAirbag | quote }}
  STRUDEL_INHABITANT: {{ .Values.appreciate.strudelInhabitant | quote }}
  TERRIFY_TASTEFUL_HARMONICA: {{ .Values.appreciate.terrifyTastefulHarmonica | quote
    }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "appreciate.fullname" . }}-appreciate
  labels:
  {{- include "appreciate.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: appreciate
spec:
  replicas: {{ .Values.appreciate.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: appreciate
      app.kubernetes.io/name: antibody
    {{- include "appreciate.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: appreciate
        app.kubernetes.io/name: antibody
      {{- include "appreciate.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 2e594b08e5ac892976661c224811755d805925fdba3bf7158849cc5f50bae639
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "appreciate.fullname" . }}-appreciate
        image: {{ .Values.appreciate.appreciate.image.repository }}:{{ .Values.appreciate.appreciate.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.appreciate.appreciate.imagePullPolicy }}
        name: appreciate
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.appreciate.appreciate.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.appreciate.appreciate.containerSecurityContext
          | nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "appreciate.fullname" . }}-appreciate
  labels:
  {{- include "appreciate.labels" . | nindent 4 }}
spec:
  type: {{ .Values.appreciate.type }}
  selector:
    app.kubernetes.io/instance: appreciate
    app.kubernetes.io/name: antibody
  {{- include "appreciate.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.appreciate.ports | toYaml | nindent 2 -}}
appreciate:
  aliasSootheCurtain: deadpan
  appreciate:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  carterSatisfy: blot
  glenDisciplineRegistry: hybridization
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  rambunctiousAirbag: gateway
  replicas: 1
  strudelInhabitant: horn
  terrifyTastefulHarmonica: bowler
  type: ClusterIP
kubernetesClusterDomain: cluster.local
