# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "blazer.fullname" . }}-blazer
  labels:
  {{- include "blazer.labels" . | nindent 4 }}
data:
  ACUPUNCTURE_SERUM_DIFFERENT: {{ .Values.blazer.acupunctureSerumDifferent | quote
    }}
  ASTERISK_INHERITANCE: {{ .Values.blazer.asteriskInheritance | quote }}
  ATTACK: {{ .Values.blazer.attack | quote }}
  HYPOTHESIZE: {{ .Values.blazer.hypothesize | quote }}
  MISFIT_SURROUNDINGS: {{ .Values.blazer.misfitSurroundings | quote }}
  MORTISE_TAMALE: {{ .Values.blazer.mortiseTamale | quote }}
  PATENTEE_PACKAGING_RETOUCHING: {{ .Values.blazer.patenteePackagingRetouching |
    quote }}
  STATUS_SMOGGY_CHOWDER: {{ .Values.blazer.statusSmoggyChowder | quote }}
  SUPPER: {{ .Values.blazer.supper | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "blazer.fullname" . }}-blazer
  labels:
  {{- include "blazer.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: blazer
spec:
  replicas: {{ .Values.blazer.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: blazer
      app.kubernetes.io/name: fabric
    {{- include "blazer.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: blazer
        app.kubernetes.io/name: fabric
      {{- include "blazer.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 67a1cb4a6cc694375a0e9f46b15a80c209ade1812069a1a066e9f326f3961408
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "blazer.fullname" . }}-blazer
        image: {{ .Values.blazer.blazer.image.repository }}:{{ .Values.blazer.blazer.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.blazer.blazer.imagePullPolicy }}
        name: blazer
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.blazer.blazer.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.blazer.blazer.containerSecurityContext | nindent
          10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "blazer.fullname" . }}-blazer
  labels:
  {{- include "blazer.labels" . | nindent 4 }}
spec:
  type: {{ .Values.blazer.type }}
  selector:
    app.kubernetes.io/instance: blazer
    app.kubernetes.io/name: fabric
  {{- include "blazer.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.blazer.ports | toYaml | nindent 2 -}}
blazer:
  acupunctureSerumDifferent: wisdom
  asteriskInheritance: cake
  attack: hydrocarbon
  blazer:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  hypothesize: armour
  misfitSurroundings: plate
  mortiseTamale: guerrilla
  patenteePackagingRetouching: knit
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  statusSmoggyChowder: soldier
  supper: regret
  type: ClusterIP
kubernetesClusterDomain: cluster.local
