# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "feast.fullname" . }}-feast
  labels:
  {{- include "feast.labels" . | nindent 4 }}
data:
  ACTRESS_BOND: {{ .Values.feast.actressBond | quote }}
  BASKET_KID: {{ .Values.feast.basketKid | quote }}
  COUGH: {{ .Values.feast.cough | quote }}
  HANDLE_LAVA: {{ .Values.feast.handleLava | quote }}
  HIKING: {{ .Values.feast.hiking | quote }}
  MANUFACTURING_LOWLY_SINCERE: {{ .Values.feast.manufacturingLowlySincere | quote
    }}
  OUNCE_INJUNCTION_PHASE: {{ .Values.feast.ounceInjunctionPhase | quote }}
  OVERJOYED_SCREAMER: {{ .Values.feast.overjoyedScreamer | quote }}
  PLAYROOM_NEGLECT_MED: {{ .Values.feast.playroomNeglectMed | quote }}
  SPELLING_CROCODILE: {{ .Values.feast.spellingCrocodile | quote }}
  VALIDITY: {{ .Values.feast.validity | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "feast.fullname" . }}-feast
  labels:
  {{- include "feast.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: feast
spec:
  replicas: {{ .Values.feast.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: feast
      app.kubernetes.io/name: accept
    {{- include "feast.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: feast
        app.kubernetes.io/name: accept
      {{- include "feast.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 82c633486847094b0d2255b4cb1754e2692946fe62093a3eb9b3c7c1ae71c0d7
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "feast.fullname" . }}-feast
        image: {{ .Values.feast.feast.image.repository }}:{{ .Values.feast.feast.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.feast.feast.imagePullPolicy }}
        name: feast
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.feast.feast.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.feast.feast.containerSecurityContext | nindent
          10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "feast.fullname" . }}-feast
  labels:
  {{- include "feast.labels" . | nindent 4 }}
spec:
  type: {{ .Values.feast.type }}
  selector:
    app.kubernetes.io/instance: feast
    app.kubernetes.io/name: accept
  {{- include "feast.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.feast.ports | toYaml | nindent 2 -}}
feast:
  actressBond: spy
  basketKid: chance
  cough: batting
  feast:
    containerSecurityContext: {}
    image:
      repository: nginx
      tag: latest
    imagePullPolicy: IfNotPresent
    resources:
      limits:
        cpu: 200m
        memory: 200Mi
      requests:
        cpu: 200m
        memory: 200Mi
  handleLava: recipe
  hiking: food
  manufacturingLowlySincere: tough
  ounceInjunctionPhase: interest
  overjoyedScreamer: tobacco
  playroomNeglectMed: fireplace
  ports:
  - name: http
    port: 80
    protocol: TCP
    targetPort: http
  replicas: 1
  spellingCrocodile: pass
  type: ClusterIP
  validity: faculty
kubernetesClusterDomain: cluster.local
