feat(k8s/immich): add persistent NFS cache for library backup
This commit is contained in:
@@ -1,3 +1,15 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: immich-backup-cache
|
||||||
|
namespace: immich
|
||||||
|
spec:
|
||||||
|
accessModes: ["ReadWriteOnce"]
|
||||||
|
storageClassName: nfs-synology-ssd
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
|
---
|
||||||
apiVersion: batch/v1
|
apiVersion: batch/v1
|
||||||
kind: CronJob
|
kind: CronJob
|
||||||
metadata:
|
metadata:
|
||||||
@@ -119,6 +131,8 @@ spec:
|
|||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: immich-backup-config
|
name: immich-backup-config
|
||||||
key: B2_ACCOUNT_KEY
|
key: B2_ACCOUNT_KEY
|
||||||
|
- name: RESTIC_CACHE_DIR
|
||||||
|
value: /cache
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: secrets
|
- name: secrets
|
||||||
mountPath: /secrets
|
mountPath: /secrets
|
||||||
@@ -126,6 +140,8 @@ spec:
|
|||||||
- name: library
|
- name: library
|
||||||
mountPath: /data
|
mountPath: /data
|
||||||
readOnly: true
|
readOnly: true
|
||||||
|
- name: cache
|
||||||
|
mountPath: /cache
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
cpu: 100m
|
cpu: 100m
|
||||||
@@ -139,3 +155,6 @@ spec:
|
|||||||
- name: library
|
- name: library
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
claimName: immich-library
|
claimName: immich-library
|
||||||
|
- name: cache
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: immich-backup-cache
|
||||||
|
|||||||
Reference in New Issue
Block a user