From a19074d2042b16415257ecfc266cc87077841e66 Mon Sep 17 00:00:00 2001 From: Matt Reeves Date: Wed, 3 Jul 2024 21:40:55 -0400 Subject: [PATCH] adding nas config --- apps/production/radarr/deployment.yaml | 12 ++++++++++++ configmaps/nas-configmap.yaml | 6 ++++++ storage/volumes/nas-pv.yaml | 13 +++++++++++++ storage/volumes/nas-pvc.yaml | 11 +++++++++++ 4 files changed, 42 insertions(+) create mode 100644 configmaps/nas-configmap.yaml create mode 100644 storage/volumes/nas-pv.yaml create mode 100644 storage/volumes/nas-pvc.yaml diff --git a/apps/production/radarr/deployment.yaml b/apps/production/radarr/deployment.yaml index 5bdb442..c385577 100644 --- a/apps/production/radarr/deployment.yaml +++ b/apps/production/radarr/deployment.yaml @@ -30,6 +30,13 @@ spec: volumeMounts: - mountPath: /config name: config + - mountPath: /data + name: nas + envFrom: + - secretRef: + name: nas-secret + - configMapRef: + name: nas-configmap volumeClaimTemplates: - metadata: name: config @@ -39,3 +46,8 @@ spec: requests: storage: 5Gi storageClassName: longhorn + volumes: + - name: nas + nfs: + path: ${EXPORT_PATH} + server: ${NAS_SERVER} diff --git a/configmaps/nas-configmap.yaml b/configmaps/nas-configmap.yaml new file mode 100644 index 0000000..5b7177b --- /dev/null +++ b/configmaps/nas-configmap.yaml @@ -0,0 +1,6 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: nas-configmap +data: + exportPath: /mnt/thePool/thePoolShare diff --git a/storage/volumes/nas-pv.yaml b/storage/volumes/nas-pv.yaml new file mode 100644 index 0000000..9b2d196 --- /dev/null +++ b/storage/volumes/nas-pv.yaml @@ -0,0 +1,13 @@ +apiVersion: v1 +kind: PersistentVolume +metadata: + name: nas-pv +spec: + capacity: + storage: 12Ti + accessModes: + - ReadWriteMany + nfs: + path: /mnt/thePool/thePoolShare + server: ${NAS_SERVER} + persistentVolumeReclaimPolicy: Retain diff --git a/storage/volumes/nas-pvc.yaml b/storage/volumes/nas-pvc.yaml new file mode 100644 index 0000000..1946a68 --- /dev/null +++ b/storage/volumes/nas-pvc.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: nas-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 30Gi + volumeName: nas-pv