Provision Ombi PostgreSQL with CloudNativePG
This commit is contained in:
1 parent
0e7b8cbb62
commit
dad7b675c4
8 files changed
+81
No files matched your search
@@ -0,0 +1,18 @@
|
||||
apiVersion: postgresql.cnpg.io/v1
|
||||
kind: Cluster
|
||||
metadata:
|
||||
name: ombi-cnpg
|
||||
namespace: ombi
|
||||
spec:
|
||||
instances: 1
|
||||
enableSuperuserAccess: true
|
||||
imageName: ghcr.io/cloudnative-pg/postgresql:17.11-standard-trixie
|
||||
bootstrap:
|
||||
initdb:
|
||||
database: ombi
|
||||
owner: ombi
|
||||
secret:
|
||||
name: ombi-cnpg-bootstrap
|
||||
storage:
|
||||
size: 5Gi
|
||||
storageClass: rook-ceph-block
|
||||
@@ -0,0 +1,4 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- cluster.yaml
|
||||
@@ -0,0 +1,15 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: postgresql
|
||||
namespace: ombi
|
||||
spec:
|
||||
ports:
|
||||
- name: postgresql
|
||||
port: 5432
|
||||
protocol: TCP
|
||||
targetPort: 5432
|
||||
selector:
|
||||
cnpg.io/cluster: ombi-cnpg
|
||||
cnpg.io/instanceRole: primary
|
||||
type: ClusterIP
|
||||
@@ -0,0 +1,4 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- service.yaml
|
||||
@@ -0,0 +1,15 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: postgresql
|
||||
namespace: ombi
|
||||
spec:
|
||||
ports:
|
||||
- name: postgresql
|
||||
port: 5432
|
||||
protocol: TCP
|
||||
targetPort: 5432
|
||||
selector:
|
||||
cnpg.io/cluster: ombi-cnpg
|
||||
cnpg.io/instanceRole: primary
|
||||
type: ClusterIP
|
||||
@@ -77,6 +77,7 @@ resources:
|
||||
- ombi-namespace.yaml
|
||||
- ombi-postgresql-secret.yaml
|
||||
- ombi-postgresql.yaml
|
||||
- ombi-cnpg.yaml
|
||||
- tautulli.yaml
|
||||
- uptime-kuma.yaml
|
||||
- grafana.yaml
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: ombi-cnpg
|
||||
namespace: argocd
|
||||
annotations:
|
||||
argocd.argoproj.io/sync-wave: "0"
|
||||
spec:
|
||||
project: ombi
|
||||
source:
|
||||
repoURL: https://code.brunner.ninja/feedc0de/homelab-gitops.git
|
||||
targetRevision: main
|
||||
path: apps/ombi-postgresql/cluster
|
||||
destination:
|
||||
server: https://kubernetes.default.svc
|
||||
namespace: ombi
|
||||
syncPolicy:
|
||||
automated:
|
||||
enabled: true
|
||||
prune: true
|
||||
selfHeal: true
|
||||
@@ -15,6 +15,9 @@ spec:
|
||||
destinations:
|
||||
- namespace: ombi
|
||||
server: https://kubernetes.default.svc
|
||||
clusterResourceWhitelist:
|
||||
- group: postgresql.cnpg.io
|
||||
kind: Cluster
|
||||
namespaceResourceWhitelist:
|
||||
- group: ""
|
||||
kind: ConfigMap
|
||||
|
||||
Reference in new issue
Block a user