apiVersion: apps/v1
kind: Deployment
metadata:
  name: jellyfin-server
spec:
  selector:
    matchLabels:
      app: jellyfin-server
  template:
    metadata:
      labels:
        app: jellyfin-server
    spec:
      containers:
      - name: jellyfin-server
        image: jellyfin/jellyfin
        resources:
          limits:
            memory: "2Gi"
            cpu: "2"
        ports:
        - containerPort: 8096
          name: jellyfin
        env:
        - name: TZ
          value: Europe/Berlin
        volumeMounts:
        - name: config
          mountPath: /config
        - name: media
          mountPath: /media
        livenessProbe:
          httpGet:
            path: /health
            port: 8096
          initialDelaySeconds: 100
          periodSeconds: 15
      volumes:
      - name: config
        persistentVolumeClaim:
          claimName: config
      - name: media
        persistentVolumeClaim:
          claimName: media