feat: overhaul

This commit is contained in:
auricom
2025-01-04 00:00:04 +01:00
parent b14022014b
commit 0c9529c7a2
408 changed files with 3187 additions and 2380 deletions

View File

@@ -4,7 +4,6 @@ apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: outline
namespace: default
spec:
secretStoreRef:
kind: ClusterSecretStore
@@ -19,19 +18,30 @@ spec:
AWS_SECRET_ACCESS_KEY: "{{ .OUTLINE_AWS_SECRET_ACCESS_KEY }}"
SECRET_KEY: "{{ .OUTLINE_SECRET_KEY }}"
UTILS_SECRET: "{{ .OUTLINE_UTILS_SECRET }}"
DATABASE_URL: "postgresql://{{ .POSTGRES_USER }}:{{ .POSTGRES_PASS }}@postgres16-rw.database.svc.cluster.local/outline"
OIDC_CLIENT_SECRET: "{{ .OUTLINE_OAUTH_CLIENT_SECRET }}"
# PGSSLMODE: require
# Postgres Init
INIT_POSTGRES_DBNAME: outline
INIT_POSTGRES_HOST: postgres16-rw.database.svc.cluster.local
INIT_POSTGRES_USER: "{{ .POSTGRES_USER }}"
INIT_POSTGRES_PASS: "{{ .POSTGRES_PASS }}"
INIT_POSTGRES_SUPER_PASS: "{{ .POSTGRES_SUPER_PASS }}"
dataFrom:
- extract:
key: authelia
- extract:
key: cloudnative-pg
- extract:
key: outline
---
# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/external-secrets.io/externalsecret_v1beta1.json
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: outline-db
namespace: default
spec:
secretStoreRef:
kind: ClusterSecretStore
name: crunchy-pgo-secrets
target:
name: outline-db-secret
template:
engineVersion: v2
data:
DATABASE_URL: 'postgresql://{{ index . "user" }}:{{ index . "password" }}@{{ index . "host" }}/{{ index . "dbname" }}'
PGSSLMODE: require
dataFrom:
- extract:
key: postgres-pguser-outline

View File

@@ -4,7 +4,6 @@ apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: &app outline
namespace: default
spec:
interval: 30m
chart:
@@ -32,15 +31,7 @@ spec:
outline:
annotations:
reloader.stakater.com/auto: "true"
secret.reloader.stakater.com/reload: authelia-secret
initContainers:
init-db:
image:
repository: ghcr.io/onedr0p/postgres-init
tag: 16
envFrom: &envFrom
- secretRef:
name: outline-secret
secret.reloader.stakater.com/reload: authelia-secret,outline-db-secret
containers:
app:
image:
@@ -49,6 +40,8 @@ spec:
envFrom:
- secretRef:
name: outline-secret
- secretRef:
name: outline-db-secret
env:
AWS_REGION: us-east-1
AWS_S3_ACL: private
@@ -58,6 +51,7 @@ spec:
ENABLE_UPDATES: "false"
FILE_STORAGE_UPLOAD_MAX_SIZE: "26214400"
LOG_LEVEL: debug
NODE_TLS_REJECT_UNAUTHORIZED: "0"
OIDC_AUTH_URI: "https://auth.${SECRET_EXTERNAL_DOMAIN}/api/oidc/authorization"
OIDC_CLIENT_ID: outline
OIDC_DISPLAY_NAME: Authelia
@@ -94,7 +88,7 @@ spec:
ingress:
app:
enabled: true
className: nginx
className: internal
annotations:
hajimari.io/icon: mdi:text-box-multiple
gethomepage.dev/enabled: "true"

View File

@@ -2,7 +2,6 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/SchemaStore/schemastore/master/src/schemas/json/kustomization.json
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: default
resources:
- ./externalsecret.yaml
- ./helmrelease.yaml

View File

@@ -1,5 +1,5 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/kustomization-kustomize-v1.json
# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/kustomize.toolkit.fluxcd.io/kustomization_v1.json
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
@@ -16,6 +16,7 @@ spec:
kind: GitRepository
name: home-ops-kubernetes
dependsOn:
- name: crunchy-postgres-operator-cluster
- name: dragonfly-cluster
- name: external-secrets-stores
wait: false