---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: tautulli
  namespace: media
  labels:
    app: tautulli
spec:
  replicas: 1
  selector:
    matchLabels:
      app: tautulli
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        app: tautulli
    spec:
      containers:
        - name: tautulli
          image: lscr.io/linuxserver/tautulli:v2.8.1-ls26
          imagePullPolicy: IfNotPresent
          env:
            - name: TZ
              value: Europe/Zurich
            - name: PGID
              value: "2000"
            - name: PUID
              value: "2000"
          ports:
            - name: http
              containerPort: 8181
          startupProbe:
            httpGet:
              path: /status
              port: http
            initialDelaySeconds: 20
            failureThreshold: 30
            timeoutSeconds: 3
            periodSeconds: 5
          livenessProbe:
            httpGet:
              path: /status
              port: http
            initialDelaySeconds: 20
            failureThreshold: 5
            timeoutSeconds: 3
            periodSeconds: 30
          volumeMounts:
            - name: data
              mountPath: /config
            - name: backup
              mountPath: /config/backups
      restartPolicy: Always
      automountServiceAccountToken: false
      volumes:
        - name: data
          persistentVolumeClaim:
            claimName: tautulli-data
        - name: backup
          persistentVolumeClaim:
            claimName: tautulli-backup
