# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "gall-bladder.fullname" . }}-gall-bladder
  labels:
  {{- include "gall-bladder.labels" . | nindent 4 }}
data:
  ASTROLOGY: {{ .Values.gallBladder.astrology | quote }}
  CARPET_LYCRA_GRAIN: {{ .Values.gallBladder.carpetLycraGrain | quote }}
  HURRIED: {{ .Values.gallBladder.hurried | quote }}
  HURT_TON: {{ .Values.gallBladder.hurtTon | quote }}
  MOTORCAR_LOVELY_VEX: {{ .Values.gallBladder.motorcarLovelyVex | quote }}
  PROGRAMME_DYNAMIC_USHER: {{ .Values.gallBladder.programmeDynamicUsher | quote }}
  THERMOSTAT: {{ .Values.gallBladder.thermostat | quote }}
  UTILISATION_FORGET_BILLBOARD: {{ .Values.gallBladder.utilisationForgetBillboard
    | quote }}
  WAKE: {{ .Values.gallBladder.wake | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "gall-bladder.fullname" . }}-gall-bladder
  labels:
  {{- include "gall-bladder.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: gall-bladder
spec:
  replicas: {{ .Values.gallBladder.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: gall-bladder
      app.kubernetes.io/name: solicitation
    {{- include "gall-bladder.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: gall-bladder
        app.kubernetes.io/name: solicitation
      {{- include "gall-bladder.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: ce8320d8e578f329cfc824f13f57fea22cae49a120b57e91c04a30b829fd27e8
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "gall-bladder.fullname" . }}-gall-bladder
        image: {{ .Values.gallBladder.gallBladder.image.repository }}:{{ .Values.gallBladder.gallBladder.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.gallBladder.gallBladder.imagePullPolicy }}
        name: gall-bladder
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.gallBladder.gallBladder.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.gallBladder.gallBladder.containerSecurityContext
          | nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "gall-bladder.fullname" . }}-gall-bladder
  labels:
  {{- include "gall-bladder.labels" . | nindent 4 }}
spec:
  type: {{ .Values.gallBladder.type }}
  selector:
    app.kubernetes.io/instance: gall-bladder
    app.kubernetes.io/name: solicitation
  {{- include "gall-bladder.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.gallBladder.ports | toYaml | nindent 2 -}}
gallBladder:
  astrology: bracket
  carpetLycraGrain: misspell
  gallBladder:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  hurried: ruler
  hurtTon: dolman
  motorcarLovelyVex: swing
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  programmeDynamicUsher: propane
  replicas: 1
  thermostat: houseboat
  type: ClusterIP
  utilisationForgetBillboard: men
  wake: construction
kubernetesClusterDomain: cluster.local
