authentik cluster refactor

This commit is contained in:
2025-06-10 16:32:29 -04:00
parent b43e1a8021
commit 95204ab87d
3 changed files with 13 additions and 11 deletions

View File

@@ -1,9 +1,10 @@
apiVersion: postgresql.cnpg.io/v1 apiVersion: postgresql.cnpg.io/v1
kind: Cluster kind: Cluster
metadata: metadata:
name: authentik-postgres name: postgres-cluster
namespace: authentik namespace: authentik
annotations: annotations:
# needed to allow for recovery from same name cluster backup
cnpg.io/skipEmptyWalArchiveCheck: enabled cnpg.io/skipEmptyWalArchiveCheck: enabled
spec: spec:
instances: 3 instances: 3
@@ -15,20 +16,21 @@ spec:
login: true login: true
bootstrap: bootstrap:
# initdb: initdb:
# database: authentik database: authentik
# owner: authentik owner: authentik
# secret: secret:
# name: authentik-postgres-credentials name: authentik-postgres-credentials
recovery: # NOTE: uncomment this and commend the above initdb when recovering
source: authentik-postgres # recovery:
# source: postgres-cluster
storage: storage:
size: 8Gi size: 8Gi
storageClass: longhorn-pg storageClass: longhorn-pg
externalClusters: externalClusters:
- name: authentik-postgres - name: postgres-cluster
barmanObjectStore: barmanObjectStore:
destinationPath: "s3://mthomson-cnpg-backup/authentik/" destinationPath: "s3://mthomson-cnpg-backup/authentik/"
endpointURL: "https://s3.ca-central-1.wasabisys.com" endpointURL: "https://s3.ca-central-1.wasabisys.com"

View File

@@ -17,7 +17,7 @@ spec:
authentik: authentik:
secret_key: file:///secret-key/key secret_key: file:///secret-key/key
postgresql: postgresql:
host: authentik-postgres-rw host: postgres-cluster-rw
user: file:///postgres-creds/username user: file:///postgres-creds/username
password: file:///postgres-creds/password password: file:///postgres-creds/password
server: server:

View File

@@ -8,4 +8,4 @@ spec:
backupOwnerReference: self backupOwnerReference: self
#immediate: true #immediate: true
cluster: cluster:
name: authentik-postgres name: postgres-cluster