theshire/kubernetes/apps/database/crunchy-postgres-operator/cluster/externalsecret.yaml

38 lines
1 KiB
YAML
Raw Normal View History

2024-04-09 05:17:44 -05:00
---
2024-04-17 18:45:44 -05:00
# yaml-language-server: $schema=https://ks.hsn.dev/external-secrets.io/externalsecret_v1beta1.json
2024-04-09 05:17:44 -05:00
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: &name crunchy-postgres
spec:
secretStoreRef:
kind: ClusterSecretStore
name: onepassword-connect
target:
name: crunchy-postgres-secret
template:
engineVersion: v2
data:
s3.conf: |
[global]
repo1-s3-key={{ .minio_crunchy_postgres_access_key }}
repo1-s3-key-secret={{ .minio_crunchy_postgres_secret_key }}
encryption.conf: |
[global]
repo1-cipher-pass={{ .crunchy_postgres_backup_encryption_cipher }}
dataFrom:
- extract:
key: crunchy-postgres
rewrite:
- regexp:
source: "(.*)"
target: "crunchy_postgres_$1"
- extract:
key: minio
rewrite:
- regexp:
source: "[-]"
target: "_"
- regexp:
source: "(.*)"
target: "minio_$1"