apiVersion: batch/v1
kind: Job
metadata:
  name: armycookbot
spec:
  template:
    spec:
      containers:
      - name: armycookbot
        image: registry.gitlab.com/btbtravis/army-cook:0.0.6.alpha.1
        volumeMounts:
        - name: master-txt-volume
          mountPath: /txts/master
        - name: sayings-txt-volume
          mountPath: /txts/sayings
        env:
        - name: CONSUMER_KEY
          valueFrom:
            configMapKeyRef:
              key: CONSUMER_KEY
              name: armycook-config
        - name: CONSUMER_SECRET
          valueFrom:
            configMapKeyRef:
              key: CONSUMER_SECRET
              name: armycook-config
        - name: ACCESS_TOKEN
          valueFrom:
            configMapKeyRef:
              key: ACCESS_TOKEN
              name: armycook-config
        - name: ACCESS_TOKEN_SECRET
          valueFrom:
            configMapKeyRef:
              key: ACCESS_TOKEN_SECRET
              name: armycook-config
        - name: ORIGIN_DATE
          valueFrom:
            configMapKeyRef:
              key: ORIGIN_DATE
              name: armycook-config
      restartPolicy: Never
      volumes:
      - name: master-txt-volume
        configMap:
          name: master-txt
      - name: sayings-txt-volume
        configMap:
          name: sayings-txt
  backoffLimit: 4
