From d235ae157eea67d876628a19ae06aaec30717bb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Cluseau?= Date: Wed, 4 Oct 2023 21:38:09 +0200 Subject: [PATCH] step-0 --- templates/pre-sync.yaml | 33 +++++++++++++++++++++++++++++++-- values.yaml | 10 +++++++--- 2 files changed, 38 insertions(+), 5 deletions(-) diff --git a/templates/pre-sync.yaml b/templates/pre-sync.yaml index be8ffe6..b17b8c1 100644 --- a/templates/pre-sync.yaml +++ b/templates/pre-sync.yaml @@ -1,5 +1,5 @@ {{ if .Values.etcd.backup }} - +# ------------------------------------------------------------------------ --- apiVersion: batch/v1 kind: Job @@ -18,7 +18,6 @@ spec: volumeMounts: - mountPath: /data name: data - subPath: etcd command: - etcdctl - --endpoints=http://etcd:2379 @@ -31,4 +30,34 @@ spec: persistentVolumeClaim: claimName: etcd-backups +# ------------------------------------------------------------------------ +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: etcd-backups-view +spec: + replicas: 1 + selector: + matchLabels: + app: etcd-backups-view + template: + metadata: + labels: + app: etcd-backups-view + spec: + restartPolicy: Never + containers: + - name: etcd-backups-view + image: alpine:3.18 + stdin: true + volumeMounts: + - mountPath: /data + name: data + subPath: etcd + volumes: + - name: data + persistentVolumeClaim: + claimName: etcd-backups + {{ end }} diff --git a/values.yaml b/values.yaml index 9ba8aa5..a939bfa 100644 --- a/values.yaml +++ b/values.yaml @@ -9,11 +9,15 @@ app: migrate: repo: gitea.demos.novit.tech/demo/migrate #tag: v1 - tag: v2 + #tag: v2 etcd: - backup: true - tag: v3.5.9 + backup: false + #backup: true + + tag: v3.5.8 + #tag: v3.5.9 + storage: class: local request: 1Gi