apiVersion: batch/v1beta1
kind: CronJob
metadata:
  name: do-snapshotter
spec:
  schedule: "0 1 * * *"
  jobTemplate:
    spec:
      template:
        spec:
          containers:
          - name: do-snapshotter
            image: dtrierweiler/do-snapshotter
            env:
              - name: DIGITALOCEAN_TOKEN
                valueFrom:
                  secretKeyRef:
                    name: do-token
                    key: access-token
          restartPolicy: Never
