apiVersion: apps/v1
kind: Deployment
metadata:
  name: jellyseerr
  namespace: stack-arr
spec:
  replicas: 1
  selector:
    matchLabels:
      app: jellyseerr
  template:
    metadata:
      labels:
        app: jellyseerr
    spec:
      imagePullSecrets:
      - name: regcred
      containers:
      - name: jellyseerr
        image: fallenbagel/jellyseerr:2.7.3
        ports:
          - containerPort: 5055
            name: webui
        env:
        - name: TZ
          value: 'Etc/UTC'
        - name: LOG_LEVEL
          value: 'debug'
        - name: DB_TYPE
          value: 'postgres'
        - name: DB_HOST
          value: 'stolon-proxy-service.postgresql.svc.cluster.local'
        - name: DB_PORT
          value: '5432'
        - name: DB_USER
          valueFrom:
            secretKeyRef:
              name: jellyseerr-secret
              key: username
        - name: DB_PASS
          valueFrom:
            secretKeyRef:
              name: jellyseerr-secret
              key: password
        - name: DB_NAME
          valueFrom:
            secretKeyRef:
              name: jellyseerr-secret
              key: maindb
        - name: DB_LOG_QUERIES
          value: 'false'
        volumeMounts:
        - name: config
          mountPath: /app/config
      volumes:
      - name: config
        persistentVolumeClaim:
          claimName: jellyseerr-config-pvc




