feat(grafana): provision new DB
All checks were successful
Renovate / renovate (push) Successful in 36s

This commit is contained in:
Peter 2024-08-20 18:16:47 +02:00
parent 2a7240b3f6
commit 2ed60f7f25
Signed by: prskr
GPG key ID: F56BED6903BC5E37
4 changed files with 25 additions and 5 deletions

View file

@ -74,17 +74,17 @@ grafana:
enabled: false enabled: false
envFromSecrets: envFromSecrets:
- name: grafana-auth - name: grafana-auth
- name: grafana-db - name: db-credentials-grafana
grafana.ini: grafana.ini:
server: server:
domain: grafana.icb4dc0.de domain: grafana.icb4dc0.de
root_url: "https://%(domain)s" root_url: "https://%(domain)s"
database: database:
type: postgres type: postgres
host: default-cluster-primary.postgres.svc:5432 host: app-cluster-pooler-rw.postgres.svc:5432
name: grafana name: "${DATABASE_NAME}"
user: "${GF_DB_USER}" user: "${LOGIN}"
password: "${GF_DB_PASSWORD}" password: "${PASSWORD}"
ssl_mode: require ssl_mode: require
auth: auth:
disable_login_form: true disable_login_form: true

View file

@ -7,6 +7,8 @@ resources:
- resources/secret.grafana-admin.yaml - resources/secret.grafana-admin.yaml
- resources/secret.auth.yaml - resources/secret.auth.yaml
- resources/secret.db.yaml - resources/secret.db.yaml
- resources/db/db.yaml
- resources/db/user.yaml
- resources/http_routes.grafana.yaml - resources/http_routes.grafana.yaml
helmCharts: helmCharts:

View file

@ -0,0 +1,8 @@
---
apiVersion: db.movetokube.com/v1alpha1
kind: Postgres
metadata:
name: grafana
spec:
database: grafana
dropOnDelete: false

View file

@ -0,0 +1,10 @@
---
apiVersion: db.movetokube.com/v1alpha1
kind: PostgresUser
metadata:
name: grafana
spec:
role: grafana
database: grafana
secretName: db-credentials
privileges: OWNER