68 lines
2.1 KiB
YAML
68 lines
2.1 KiB
YAML
---
|
|
# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/external-secrets.io/externalsecret_v1beta1.json
|
|
apiVersion: external-secrets.io/v1beta1
|
|
kind: ExternalSecret
|
|
metadata:
|
|
name: &name sonarr
|
|
spec:
|
|
target:
|
|
name: *name
|
|
deletionPolicy: Delete
|
|
template:
|
|
type: Opaque
|
|
data:
|
|
# App
|
|
SONARR__AUTH__APIKEY: "{{ .SONARR_API_KEY }}"
|
|
SONARR__POSTGRES__HOST: &dbHost postgres-rw.databases.svc.cluster.local
|
|
SONARR__POSTGRES__PORT: "5432"
|
|
SONARR__POSTGRES__USER: &dbUser "{{ .SONARR_POSTGRES_USER }}"
|
|
SONARR__POSTGRES__PASSWORD: &dbPass "{{ .SONARR_POSTGRES_PASSWORD }}"
|
|
SONARR__POSTGRES__MAINDB: &dbName sonarr_main
|
|
# Postgres Init
|
|
INIT_POSTGRES_DBNAME: *dbName
|
|
INIT_POSTGRES_HOST: *dbHost
|
|
INIT_POSTGRES_USER: *dbUser
|
|
INIT_POSTGRES_PASS: *dbPass
|
|
INIT_POSTGRES_SUPER_PASS: "{{ .POSTGRES_ADMIN_PASS }}"
|
|
data:
|
|
- secretKey: SONARR_API_KEY
|
|
sourceRef:
|
|
storeRef:
|
|
name: bitwarden-login
|
|
kind: ClusterSecretStore
|
|
remoteRef:
|
|
key: &secretApiKey cccf2793-8f91-47da-be0d-63f08cdeda95
|
|
property: password
|
|
- secretKey: SONARR_POSTGRES_USER
|
|
sourceRef:
|
|
storeRef:
|
|
name: bitwarden-login
|
|
kind: ClusterSecretStore
|
|
remoteRef:
|
|
key: &secretDatabaseKey 6fbd4e66-0750-4dea-94b6-b5eb25c77c44
|
|
property: username
|
|
- secretKey: SONARR_POSTGRES_PASSWORD
|
|
sourceRef:
|
|
storeRef:
|
|
name: bitwarden-login
|
|
kind: ClusterSecretStore
|
|
remoteRef:
|
|
key: *secretDatabaseKey
|
|
property: password
|
|
- secretKey: POSTGRES_ADMIN_USER
|
|
sourceRef:
|
|
storeRef:
|
|
name: bitwarden-login
|
|
kind: ClusterSecretStore
|
|
remoteRef:
|
|
key: &secretAdminDatabaseKey 88217883-df53-4c96-aad7-f3b2142382de
|
|
property: username
|
|
- secretKey: POSTGRES_ADMIN_PASS
|
|
sourceRef:
|
|
storeRef:
|
|
name: bitwarden-login
|
|
kind: ClusterSecretStore
|
|
remoteRef:
|
|
key: *secretAdminDatabaseKey
|
|
property: password
|