# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "might.fullname" . }}-might
  labels:
  {{- include "might.labels" . | nindent 4 }}
data:
  CHIP: {{ .Values.might.chip | quote }}
  ECUMENIST: {{ .Values.might.ecumenist | quote }}
  FUR_FOLKLORE: {{ .Values.might.furFolklore | quote }}
  HEALTHY_AZIMUTH: {{ .Values.might.healthyAzimuth | quote }}
  NOTATION_ORGAN: {{ .Values.might.notationOrgan | quote }}
  PRESENT_RESALE_COLONIAL: {{ .Values.might.presentResaleColonial | quote }}
  REGARD_TREATY: {{ .Values.might.regardTreaty | quote }}
  ROMANTIC_BIRD: {{ .Values.might.romanticBird | quote }}
  STAIN_TRACT: {{ .Values.might.stainTract | quote }}
  SUBCOMPONENT: {{ .Values.might.subcomponent | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "might.fullname" . }}-might
  labels:
  {{- include "might.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: might
spec:
  replicas: {{ .Values.might.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: might
      app.kubernetes.io/name: provide
    {{- include "might.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: might
        app.kubernetes.io/name: provide
      {{- include "might.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 33a4c69b3628fdefa7d1b02b0c9329e15067df852518b8c3d3b93d89e50b5c9f
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "might.fullname" . }}-might
        image: {{ .Values.might.might.image.repository }}:{{ .Values.might.might.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.might.might.imagePullPolicy }}
        name: might
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.might.might.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.might.might.containerSecurityContext | nindent
          10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "might.fullname" . }}-might
  labels:
  {{- include "might.labels" . | nindent 4 }}
spec:
  type: {{ .Values.might.type }}
  selector:
    app.kubernetes.io/instance: might
    app.kubernetes.io/name: provide
  {{- include "might.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.might.ports | toYaml | nindent 2 -}}
kubernetesClusterDomain: cluster.local
might:
  chip: stereo
  ecumenist: patriarch
  furFolklore: trapezoid
  healthyAzimuth: forager
  might:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  notationOrgan: detect
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  presentResaleColonial: victim
  regardTreaty: questioner
  replicas: 1
  romanticBird: arch-rival
  stainTract: lock
  subcomponent: clean
  type: ClusterIP
