apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: taskd
spec:
  selector:
    matchLabels:
      app: taskd
  serviceName: "taskd"
  replicas: 1
  template:
    metadata:
      labels:
        app: taskd
    spec:
      containers:
      - name: taskd
        image: docker.pkg.github.com/wasv/taskwarrior-docker/taskserver
        imagePullPolicy: "Always"
        env:
        - name: TASKDDATA
          value: "/data/taskd"
        volumeMounts:
        - name: data
          mountPath: /data/taskd
      restartPolicy: Always
  volumeClaimTemplates:
  - metadata:
      name: data
    spec:
      accessModes: [ "ReadWriteOnce" ]
      resources:
        requests:
          storage: 200Mi
