From cd66b1f2aa34bba732292771d7b82b77d95d903c Mon Sep 17 00:00:00 2001 From: Ryan Cavicchioni Date: Sat, 27 Jul 2024 19:14:48 -0500 Subject: [PATCH] Add storage --- kustomize/deployment.yaml | 7 +++++++ kustomize/kustomization.yaml | 1 + kustomize/storage.yaml | 11 +++++++++++ 3 files changed, 19 insertions(+) create mode 100644 kustomize/storage.yaml diff --git a/kustomize/deployment.yaml b/kustomize/deployment.yaml index 18ad462..e7cdf28 100644 --- a/kustomize/deployment.yaml +++ b/kustomize/deployment.yaml @@ -41,3 +41,10 @@ spec: port: 4567 initialDelaySeconds: 5 periodSeconds: 5 + volumeMounts: + mountPath: /data + name: data + volumes: + - name: data + persistentVolumeClaim: + claimName: volume-claim diff --git a/kustomize/kustomization.yaml b/kustomize/kustomization.yaml index 251340f..7cdab2c 100644 --- a/kustomize/kustomization.yaml +++ b/kustomize/kustomization.yaml @@ -3,6 +3,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization namespace: toy resources: + - storage.yaml - deployment.yaml - services.yaml - ingress.yaml diff --git a/kustomize/storage.yaml b/kustomize/storage.yaml new file mode 100644 index 0000000..1712b77 --- /dev/null +++ b/kustomize/storage.yaml @@ -0,0 +1,11 @@ +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: volume-claim +spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: 2Gi