feat: Add backup cronjob
Needs to run under service account created by the etcd-operator subchart so there's some template magic needed to figure out what it's called.
This commit is contained in:
parent
f34b0dc85f
commit
4c7bd01ac1
|
@ -1,12 +0,0 @@
|
||||||
apiVersion: "etcd.database.coreos.com/v1beta2"
|
|
||||||
kind: "EtcdBackup"
|
|
||||||
metadata:
|
|
||||||
name: backup
|
|
||||||
namespace: "vault-operator"
|
|
||||||
spec:
|
|
||||||
etcdEndpoints: ["https://vault-etcd-client:2379"]
|
|
||||||
storageType: ABS
|
|
||||||
clientTLSSecret: vault-etcd-client-tls
|
|
||||||
abs:
|
|
||||||
path: vault/backup
|
|
||||||
absSecret: abs
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# Use kubectl create -f restore.yaml to manually execute a restore of the vault
|
||||||
apiVersion: "etcd.database.coreos.com/v1beta2"
|
apiVersion: "etcd.database.coreos.com/v1beta2"
|
||||||
kind: "EtcdRestore"
|
kind: "EtcdRestore"
|
||||||
metadata:
|
metadata:
|
||||||
|
@ -10,5 +11,5 @@ spec:
|
||||||
name: vault-etcd
|
name: vault-etcd
|
||||||
backupStorageType: ABS
|
backupStorageType: ABS
|
||||||
abs:
|
abs:
|
||||||
path: vault/backup
|
path: vault/backup-<specify the backup name>
|
||||||
absSecret: abs
|
absSecret: abs
|
|
@ -1,4 +1,5 @@
|
||||||
{{- if .Values.backupJob.enable }}
|
{{- if .Values.backupJob.enable }}
|
||||||
|
# cronjob that creates etcdbackups using the etcd backup serviceaccount
|
||||||
apiVersion: batch/v1beta1
|
apiVersion: batch/v1beta1
|
||||||
kind: CronJob
|
kind: CronJob
|
||||||
metadata:
|
metadata:
|
||||||
|
|
Loading…
Reference in New Issue