From a910f0a73b29858db29fb88bd0dd54706d20038c Mon Sep 17 00:00:00 2001 From: Joseph Hanson Date: Wed, 1 Jan 2025 01:17:13 -0600 Subject: [PATCH] info straight from crunchy --- .../default/autobrr/app/externalsecret.yaml | 30 +++++++++++++++---- 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/kubernetes/apps/default/autobrr/app/externalsecret.yaml b/kubernetes/apps/default/autobrr/app/externalsecret.yaml index 8447eaf5..808cc28c 100644 --- a/kubernetes/apps/default/autobrr/app/externalsecret.yaml +++ b/kubernetes/apps/default/autobrr/app/externalsecret.yaml @@ -2,6 +2,30 @@ # yaml-language-server: $schema=https://ks.hsn.dev/external-secrets.io/externalsecret_v1beta1.json apiVersion: external-secrets.io/v1beta1 kind: ExternalSecret +metadata: + name: autobrr-db +spec: + secretStoreRef: + kind: ClusterSecretStore + name: onepassword-connect + target: + name: autobrr-db-secret + template: + engineVersion: v2 + data: + AUTOBRR__DATABASE_TYPE: postgres + AUTOBRR__POSTGRES_DATABASE: "{{ .dbname }}" + AUTOBRR__POSTGRES_HOST: "{{ index . \"pgbouncer-host\" }}" + AUTOBRR__POSTGRES_USER: "{{ .user }}" + AUTOBRR__POSTGRES_PASS: "{{ .password }}" + AUTOBRR__POSTGRES_PORT: "{{ .port }}" + dataFrom: + - extract: + key: postgres-pguser-sonarr-anime +--- +# yaml-language-server: $schema=https://ks.hsn.dev/external-secrets.io/externalsecret_v1beta1.json +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret metadata: name: autobrr spec: @@ -13,12 +37,6 @@ spec: template: engineVersion: v2 data: - AUTOBRR__DATABASE_TYPE: postgres - AUTOBRR__POSTGRES_DATABASE: autobrr - AUTOBRR__POSTGRES_HOST: "postgres-primary-real.database.svc" - AUTOBRR__POSTGRES_USER: "{{ .AUTOBRR_POSTGRES_USER }}" - AUTOBRR__POSTGRES_PASS: "{{ .AUTOBRR_POSTGRES_PASSWORD }}" - AUTOBRR__POSTGRES_PORT: "5432" AUTOBRR__SESSION_SECRET: "{{ .AUTOBRR_SESSION_SECRET }}" dataFrom: - extract: