39600130 by Adam Heath

Milestone: logical backups of postgres now work.

1 parent 7f159647
1 apiVersion: v1
2 kind: ConfigMap
3 metadata:
4 name: postgres-extra-config
5 ---
6 apiVersion: v1
7 kind: Secret
8 metadata:
9 name: postgres-extra-config
10 ---
1 apiVersion: kustomize.config.k8s.io/v1beta1
2 kind: Kustomization
3
4 resources:
5 - extra-config.yaml
6
1 namespace: postgres-operator 1 namespace: postgres-operator
2 backup:
3 provider: s3
4 s3:
5 access_key_id: ""
6 secret_access_key: ""
7 bucket: ""
8 region: ""
9 endpoint: ""
10 sse: "AES256"
11 wale_endpoint: ""
2 12
......
...@@ -8,7 +8,43 @@ repositories: ...@@ -8,7 +8,43 @@ repositories:
8 --- 8 ---
9 9
10 releases: 10 releases:
11 - name: postgres-extra-config
12 namespace: {{ .Values.namespace }}
13 chart: charts/extra-config
14 strategicMergePatches:
15 - apiVersion: v1
16 kind: ConfigMap
17 metadata:
18 name: postgres-extra-config
19 namespace: {{ .Values.namespace }}
20 data:
21 USE_WALE_BACKUP: "true"
22 AWS_ACCESS_KEY_ID: {{ .Values.backup.s3.access_key_id }}
23 WALE_S3_ENDPOINT: {{ .Values.backup.s3.wale_endpoint }}
24 - apiVersion: v1
25 kind: Secret
26 metadata:
27 name: postgres-extra-config
28 namespace: {{ .Values.namespace }}
29 stringData:
30 AWS_SECRET_ACCESS_KEY: {{ .Values.backup.s3.secret_access_key }}
31
11 - name: postgres-operator 32 - name: postgres-operator
12 namespace: {{ .Values.namespace }} 33 namespace: {{ .Values.namespace }}
13 chart: postgres-operator-charts/postgres-operator 34 chart: postgres-operator-charts/postgres-operator
14 disableValidation: true 35 disableValidation: true
36 values:
37 - configLogicalBackup:
38 logical_backup_provider: {{ .Values.backup.provider }}
39 logical_backup_s3_access_key_id: {{ .Values.backup.s3.access_key_id }}
40 logical_backup_s3_bucket: {{ .Values.backup.s3.bucket }}
41 logical_backup_s3_region: {{ .Values.backup.s3.region }}
42 logical_backup_s3_endpoint: {{ .Values.backup.s3.endpoint }}
43 logical_backup_s3_secret_access_key: {{ .Values.backup.s3.secret_access_key }}
44 logical_backup_s3_sse: {{ .Values.backup.s3.sse }}
45 configAwsOrGcp:
46 aws_region: {{ .Values.backup.s3.region }}
47 wal_s3_bucket: {{ .Values.backup.s3.bucket }}
48 configKubernetes:
49 pod_environment_configmap: {{ .Values.namespace }}/postgres-extra-config
50 pod_environment_secret: {{ .Values.namespace }}/postgres-extra-config
......