From 99f6236262a70886b14f9f82c9f42ebe589f37ef Mon Sep 17 00:00:00 2001 From: Michael Thomson Date: Sun, 8 Jun 2025 13:36:22 -0400 Subject: [PATCH] longhorn pg storageclass --- apps/immich/cluster.yaml | 4 ++-- .../configs/longhorn/storageclass-longhorn-pg.yaml | 13 +++++++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 infrastructure/configs/longhorn/storageclass-longhorn-pg.yaml diff --git a/apps/immich/cluster.yaml b/apps/immich/cluster.yaml index d7117a5..6a12cd7 100644 --- a/apps/immich/cluster.yaml +++ b/apps/immich/cluster.yaml @@ -5,7 +5,7 @@ metadata: namespace: immich spec: imageName: ghcr.io/tensorchord/cloudnative-vectorchord:17-0.3.0 - instances: 1 + instances: 3 postgresql: shared_preload_libraries: @@ -29,4 +29,4 @@ spec: storage: size: 8Gi - storageClass: longhorn + storageClass: longhorn-pg diff --git a/infrastructure/configs/longhorn/storageclass-longhorn-pg.yaml b/infrastructure/configs/longhorn/storageclass-longhorn-pg.yaml new file mode 100644 index 0000000..822e79b --- /dev/null +++ b/infrastructure/configs/longhorn/storageclass-longhorn-pg.yaml @@ -0,0 +1,13 @@ +kind: StorageClass +apiVersion: storage.k8s.io/v1 +metadata: + name: longhorn-pg +provisioner: driver.longhorn.io +allowVolumeExpansion: true +reclaimPolicy: Delete +volumeBindingMode: Immediate +parameters: + numberOfReplicas: "1" + staleReplicaTimeout: "30" + fromBackup: "" + dataLocality: "strict-local"