apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: seerr-seerr-chart
  labels:
    helm.sh/chart: seerr-chart-3.6.0
    app.kubernetes.io/name: seerr-chart
    app.kubernetes.io/instance: seerr
    app.kubernetes.io/version: "v3.2.0"
    app.kubernetes.io/part-of: seerr-chart
    app.kubernetes.io/managed-by: Helm
spec:
  serviceName: seerr-seerr-chart
  selector:
    matchLabels:
      app.kubernetes.io/name: seerr-chart
      app.kubernetes.io/instance: seerr
  template:
    metadata:
      labels:
        helm.sh/chart: seerr-chart-3.6.0
        app.kubernetes.io/name: seerr-chart
        app.kubernetes.io/instance: seerr
        app.kubernetes.io/version: "v3.2.0"
        app.kubernetes.io/part-of: seerr-chart
        app.kubernetes.io/managed-by: Helm
    spec:
      serviceAccountName: seerr-seerr-chart
      securityContext:
        fsGroup: 1000
        fsGroupChangePolicy: OnRootMismatch
      containers:
        - name: seerr-chart
          securityContext:
            allowPrivilegeEscalation: false
            capabilities:
              drop:
                - ALL
            privileged: false
            readOnlyRootFilesystem: false
            runAsGroup: 1000
            runAsNonRoot: true
            runAsUser: 1000
            seccompProfile:
              type: RuntimeDefault
          image: "ghcr.io/seerr-team/seerr:v3.2.0@sha256:b35ba0461c4a1033d117ac1e5968fd4cbe777899e4cbfbdeaf3d10a42a0eb7e9"
          imagePullPolicy: IfNotPresent
          ports:
            - name: http
              containerPort: 5055
              protocol: TCP
          livenessProbe:
            httpGet:
              path: /api/v1/settings/public
              port: http
            initialDelaySeconds: 20
            periodSeconds: 15
            timeoutSeconds: 3
          readinessProbe:
            httpGet:
              path: /api/v1/settings/public
              port: http
            initialDelaySeconds: 60
            periodSeconds: 15
            timeoutSeconds: 3
          resources:
            requests:
              cpu: 10m
              memory: 500Mi
          volumeMounts:
            - name: config
              mountPath: /app/config
              subPath:
      volumes:
        - name: config
          persistentVolumeClaim:
            claimName: seerr-seerr-chart-config
