feat: deploy authentik

This commit is contained in:
2024-11-09 13:06:04 -05:00
parent 43c07457b4
commit 9b80f7ad40
5 changed files with 99 additions and 3 deletions

View File

@@ -0,0 +1,18 @@
---
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: infra-authentik
namespace: flux-system
spec:
interval: 1h0m0s
path: ./infra/controllers/authentik
dependsOn:
- name: infra-1password-config
prune: true
retryInterval: 1m0s
sourceRef:
kind: GitRepository
name: flux-system
timeout: 5m0s
wait: true

View File

@@ -7,8 +7,6 @@ metadata:
spec: spec:
interval: 1h0m0s interval: 1h0m0s
path: ./infra/controllers/longhorn path: ./infra/controllers/longhorn
dependsOn:
- name: infra-metallb-config
prune: true prune: true
retryInterval: 1m0s retryInterval: 1m0s
sourceRef: sourceRef:

View File

@@ -38,3 +38,8 @@ apiVersion: v1
kind: Namespace kind: Namespace
metadata: metadata:
name: reflector-system name: reflector-system
---
apiVersion: v1
kind: Namespace
metadata:
name: authentik-system

View File

@@ -30,4 +30,3 @@ spec:
annotations: annotations:
reflector.v1.k8s.emberstack.com/reflection-allowed: "true" reflector.v1.k8s.emberstack.com/reflection-allowed: "true"
reflector.v1.k8s.emberstack.com/reflection-auto-enabled: "true" # Auto create reflection for matching namespaces reflector.v1.k8s.emberstack.com/reflection-auto-enabled: "true" # Auto create reflection for matching namespaces
# reflector.v1.k8s.emberstack.com/reflection-auto-namespaces: "traefik-system" # Control auto-reflection namespaces

View File

@@ -0,0 +1,76 @@
---
apiVersion: onepassword.com/v1
kind: OnePasswordItem
metadata:
name: authentik-secret-key
namespace: authentik-system
spec:
itemPath: "vaults/cluster/items/authentik-secret-key"
---
apiVersion: onepassword.com/v1
kind: OnePasswordItem
metadata:
name: authentik-postgresql-password
namespace: authentik-system
spec:
itemPath: "vaults/cluster/items/authentik-postgresql-password"
---
apiVersion: source.toolkit.fluxcd.io/v1
kind: HelmRepository
metadata:
name: authentik-repo
namespace: authentik-system
spec:
interval: 15m0s
url: https://charts.goauthentik.io
---
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: authentik
namespace: authentik-system
spec:
chart:
spec:
chart: authentik
reconcileStrategy: ChartVersion
sourceRef:
kind: HelmRepository
name: authentik-repo
version: 2024.10.1
interval: 1m0s
values:
authentik:
secret_key:
valueFrom:
secretKeyRef:
name: authentik-secret-key
key: password
error_reporting:
enabled: false
postgresql:
password:
valueFrom:
secretKeyRef:
name: authentik-postgresql-password
key: password
server:
ingress:
ingressClassName: traefik
enabled: true
hosts:
- authentik.yadunut.dev
tls:
- secretName: wildcard-cert-yadunut.dev-prod
hosts:
- authentik.yadunut.dev
postgresql:
enabled: true
auth:
password:
secretKeyRef:
name: authentik-postgresql-password
key: password
redis:
enabled: true