kind: CronJob
apiVersion: batch/v1beta1
metadata:
  name: bug-automation
  namespace: ocp-eng-architects
spec:
  schedule: '@hourly'
  startingDeadlineSeconds: 86400
  jobTemplate:
    spec:
      template:
        metadata:
          labels:
            app: bug-automation
        spec:
          volumes:
            - name: bugzilla-api-key
              secret:
                secretName: bugzilla-api-key
                defaultMode: 420
          containers:
            - name: bug-automation
              image: image-registry.openshift-image-registry.svc:5000/ocp-eng-architects/bug-automation:latest
              resources: {}
              volumeMounts:
                - name: bugzilla-api-key
                  readOnly: true
                  mountPath: /etc/bugzilla
              terminationMessagePath: /dev/termination-log
              terminationMessagePolicy: File
              imagePullPolicy: Always
          restartPolicy: OnFailure
  successfulJobsHistoryLimit: 3
  failedJobsHistoryLimit: 1
