# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "glimpse.fullname" . }}-glimpse
  labels:
  {{- include "glimpse.labels" . | nindent 4 }}
data:
  DIP_DESIGNATION_ROT: {{ .Values.glimpse.dipDesignationRot | quote }}
  DISILLUSIONED_ADAPTER: {{ .Values.glimpse.disillusionedAdapter | quote }}
  EYEBROWS_JUGGLE: {{ .Values.glimpse.eyebrowsJuggle | quote }}
  HUMANITY_EFFICACY: {{ .Values.glimpse.humanityEfficacy | quote }}
  MISSPELL_BLEED_POLARIZATION: {{ .Values.glimpse.misspellBleedPolarization | quote
    }}
  NOIR: {{ .Values.glimpse.noir | quote }}
  RACIAL_CARBON: {{ .Values.glimpse.racialCarbon | quote }}
  SQUEAL_OVERSIGHT_SHIRTDRESS: {{ .Values.glimpse.squealOversightShirtdress | quote
    }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "glimpse.fullname" . }}-glimpse
  labels:
  {{- include "glimpse.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: glimpse
spec:
  replicas: {{ .Values.glimpse.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: glimpse
      app.kubernetes.io/name: supply
    {{- include "glimpse.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: glimpse
        app.kubernetes.io/name: supply
      {{- include "glimpse.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: a0b3e14cb48f07532e6aa26a6000a788e3a8de27e26326ea59cd5325984bb7e8
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "glimpse.fullname" . }}-glimpse
        image: {{ .Values.glimpse.glimpse.image.repository }}:{{ .Values.glimpse.glimpse.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.glimpse.glimpse.imagePullPolicy }}
        name: glimpse
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.glimpse.glimpse.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.glimpse.glimpse.containerSecurityContext |
          nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "glimpse.fullname" . }}-glimpse
  labels:
  {{- include "glimpse.labels" . | nindent 4 }}
spec:
  type: {{ .Values.glimpse.type }}
  selector:
    app.kubernetes.io/instance: glimpse
    app.kubernetes.io/name: supply
  {{- include "glimpse.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.glimpse.ports | toYaml | nindent 2 -}}
glimpse:
  dipDesignationRot: fanlight
  disillusionedAdapter: tailor
  eyebrowsJuggle: pathology
  glimpse:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  humanityEfficacy: strife
  misspellBleedPolarization: whirlwind
  noir: therapist
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  racialCarbon: authentication
  replicas: 1
  squealOversightShirtdress: gelding
  type: ClusterIP
kubernetesClusterDomain: cluster.local
