--- apiVersion: postgresql.cnpg.io/v1 kind: Cluster metadata: name: immich-db namespace: immich labels: app: immich-db velero.io/exclude-from-backup: 'true' spec: # https://github.com/tensorchord/cloudnative-vectorchord/pkgs/container/cloudnative-vectorchord imageName: ghcr.io/tensorchord/cloudnative-vectorchord:16-0.4.3 instances: 2 resources: limits: memory: 4Gi requests: memory: 2Gi cpu: 20m # longhorn: because of easier size restriction storage: size: 4Gi storageClass: longhorn managed: roles: - name: app # we make it as superuser otherwise it can happen that immich fails to start because if is checking / creating the extensions in postgres db # it can be done manually but this makes life much easier superuser: true login: true postgresql: parameters: shared_buffers: 2GB archive_timeout: 60min shared_preload_libraries: - 'vchord.so' enableAlterSystem: true plugins: - name: barman-cloud.cloudnative-pg.io isWALArchiver: true parameters: barmanObjectName: immich-db monitoring: enablePodMonitor: true