This commit is contained in:
bom 2022-03-18 14:11:43 +01:00
parent aca8c7a397
commit 4538cc5a24

View file

@ -66,6 +66,15 @@
(cut/generate-persistent-volume {:nextcloud-data-volume-path "xx"}))))
(deftest should-generate-pvc
(is (= {:apiVersion "v1"
:kind "PersistentVolumeClaim"
:metadata {:name "cloud-pvc"
:labels {:app.kubernetes.io/application "cloud"}}
:spec {:storageClassName "local-path"
:accessModes ["ReadWriteOnce"]
:resources {:requests {:storage "50Gi"}}
:selector {:matchLabels {:app.kubernetes.io/application "cloud"}}}}
(cut/generate-pvc {})))
(is (= {:apiVersion "v1"
:kind "PersistentVolumeClaim"
:metadata {:name "cloud-pvc"
@ -74,7 +83,16 @@
:accessModes ["ReadWriteOnce"]
:resources {:requests {:storage "50Gi"}}
:selector {:matchLabels {:app.kubernetes.io/application "cloud"}}}}
(cut/generate-pvc {:nextcloud-data-volume-path "xx"}))))
(cut/generate-pvc {:nextcloud-data-volume-path "xx"})))
(is (= {:apiVersion "v1"
:kind "PersistentVolumeClaim"
:metadata {:name "cloud-pvc"
:labels {:app.kubernetes.io/application "cloud"}}
:spec {:storageClassName "manual"
:accessModes ["ReadWriteOnce"]
:resources {:requests {:storage "500Gi"}}
:selector {:matchLabels {:app.kubernetes.io/application "cloud"}}}}
(cut/generate-pvc {:pv-storage-size-gb 500}))))
(deftest should-generate-deployment
(is (= {:apiVersion "apps/v1"