# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "hundred.fullname" . }}-hundred
  labels:
  {{- include "hundred.labels" . | nindent 4 }}
data:
  ADVERTISEMENT_MANGO_TOW-TRUCK: {{ .Values.hundred.advertisementMangoTowTruck |
    quote }}
  BURRO_QUANTITY_DECADENCE: {{ .Values.hundred.burroQuantityDecadence | quote }}
  CODPIECE: {{ .Values.hundred.codpiece | quote }}
  ENTITY_HASH_MOUSTACHE: {{ .Values.hundred.entityHashMoustache | quote }}
  SQUASH_REMINDER: {{ .Values.hundred.squashReminder | quote }}
  TWISTER_TUTOR: {{ .Values.hundred.twisterTutor | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "hundred.fullname" . }}-hundred
  labels:
  {{- include "hundred.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: hundred
spec:
  replicas: {{ .Values.hundred.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: hundred
      app.kubernetes.io/name: pew
    {{- include "hundred.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: hundred
        app.kubernetes.io/name: pew
      {{- include "hundred.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: e443af5805fcc390e66835e8165958038905f8006b9a97b07bafb0b776423ea0
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "hundred.fullname" . }}-hundred
        image: {{ .Values.hundred.hundred.image.repository }}:{{ .Values.hundred.hundred.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.hundred.hundred.imagePullPolicy }}
        name: hundred
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.hundred.hundred.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.hundred.hundred.containerSecurityContext |
          nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "hundred.fullname" . }}-hundred
  labels:
  {{- include "hundred.labels" . | nindent 4 }}
spec:
  type: {{ .Values.hundred.type }}
  selector:
    app.kubernetes.io/instance: hundred
    app.kubernetes.io/name: pew
  {{- include "hundred.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.hundred.ports | toYaml | nindent 2 -}}
hundred:
  advertisementMangoTowTruck: trousers
  burroQuantityDecadence: tolerance
  codpiece: info
  entityHashMoustache: abortive
  hundred:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  squashReminder: hops
  twisterTutor: starter
  type: ClusterIP
kubernetesClusterDomain: cluster.local
