# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: {{ include "linguistics.fullname" . }}-linguistics
  labels:
  {{- include "linguistics.labels" . | nindent 4 }}
data:
  ANTIQUE_WAITING_STARBOARD: {{ .Values.linguistics.antiqueWaitingStarboard | quote
    }}
  BARE: {{ .Values.linguistics.bare | quote }}
  CAKE_TRAILPATROL: {{ .Values.linguistics.cakeTrailpatrol | quote }}
  CHECKING_EVE_MIGRATION: {{ .Values.linguistics.checkingEveMigration | quote }}
  CONTRACT_EASY_SEND: {{ .Values.linguistics.contractEasySend | quote }}
  EMPLOYMENT: {{ .Values.linguistics.employment | quote }}
  HARPSICHORD_THINKING_FINAL: {{ .Values.linguistics.harpsichordThinkingFinal | quote
    }}
  HASTE_SHOFAR: {{ .Values.linguistics.hasteShofar | quote }}
  WATERSKIING_CAVIAR: {{ .Values.linguistics.waterskiingCaviar | quote }}
  WHISPER_GRAVEL: {{ .Values.linguistics.whisperGravel | quote }} # deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "linguistics.fullname" . }}-linguistics
  labels:
  {{- include "linguistics.labels" . | nindent 4 }}
  annotations:
    kubectl.kubernetes.io/default-container: linguistics
spec:
  replicas: {{ .Values.linguistics.replicas }}
  selector:
    matchLabels:
      app.kubernetes.io/instance: linguistics
      app.kubernetes.io/name: drunk
    {{- include "linguistics.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        app.kubernetes.io/instance: linguistics
        app.kubernetes.io/name: drunk
      {{- include "linguistics.selectorLabels" . | nindent 8 }}
      annotations:
        checksum/config: 21b6277593041993ec10921460222cf907a882c443582e4fa26ddae8f812dfff
    spec:
      containers:
      - env:
        - name: KUBERNETES_CLUSTER_DOMAIN
          value: {{ quote .Values.kubernetesClusterDomain }}
        envFrom:
        - configMapRef:
            name: {{ include "linguistics.fullname" . }}-linguistics
        image: {{ .Values.linguistics.linguistics.image.repository }}:{{ .Values.linguistics.linguistics.image.tag
          | default .Chart.AppVersion }}
        imagePullPolicy: {{ .Values.linguistics.linguistics.imagePullPolicy }}
        name: linguistics
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        resources: {{- toYaml .Values.linguistics.linguistics.resources | nindent 10 }}
        securityContext: {{- toYaml .Values.linguistics.linguistics.containerSecurityContext
          | nindent 10 }}
      securityContext:
        fsGroup: 999 # service.yaml
apiVersion: v1
kind: Service
metadata:
  name: {{ include "linguistics.fullname" . }}-linguistics
  labels:
  {{- include "linguistics.labels" . | nindent 4 }}
spec:
  type: {{ .Values.linguistics.type }}
  selector:
    app.kubernetes.io/instance: linguistics
    app.kubernetes.io/name: drunk
  {{- include "linguistics.selectorLabels" . | nindent 4 }}
  ports:
	{{- .Values.linguistics.ports | toYaml | nindent 2 -}}
kubernetesClusterDomain: cluster.local
linguistics:
  antiqueWaitingStarboard: ethnicity
  bare: coast
  cakeTrailpatrol: macaroon
  checkingEveMigration: briefing
  contractEasySend: behaviour
  employment: want
  harpsichordThinkingFinal: minority
  hasteShofar: dirty
  linguistics:
    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
  type: ClusterIP
  waterskiingCaviar: weasel
  whisperGravel: commitment
