Provision Nextcloud PostgreSQL with CloudNativePG
This commit is contained in:
1 parent
44fedbbef2
commit
9396dce44b
8 files changed
+85
No files matched your search
@@ -0,0 +1,18 @@
|
||||
apiVersion: postgresql.cnpg.io/v1
|
||||
kind: Cluster
|
||||
metadata:
|
||||
name: nextcloud-cnpg
|
||||
namespace: nextcloud
|
||||
spec:
|
||||
instances: 1
|
||||
enableSuperuserAccess: true
|
||||
imageName: ghcr.io/cloudnative-pg/postgresql:17.11-standard-trixie
|
||||
bootstrap:
|
||||
initdb:
|
||||
database: nextcloud
|
||||
owner: nextcloud
|
||||
secret:
|
||||
name: nextcloud-cnpg-bootstrap
|
||||
storage:
|
||||
size: 8Gi
|
||||
storageClass: rook-ceph-block
|
||||
@@ -0,0 +1,4 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- cluster.yaml
|
||||
@@ -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: nextcloud-postgresql
|
||||
namespace: nextcloud
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- name: postgresql
|
||||
port: 5432
|
||||
protocol: TCP
|
||||
targetPort: 5432
|
||||
selector:
|
||||
cnpg.io/cluster: nextcloud-cnpg
|
||||
cnpg.io/instanceRole: primary
|
||||
@@ -120,6 +120,8 @@ resources:
|
||||
- quay-postgresql.yaml
|
||||
- quay.yaml
|
||||
- nextcloud-project.yaml
|
||||
- nextcloud-cnpg.yaml
|
||||
- nextcloud-postgresql.yaml
|
||||
- nextcloud.yaml
|
||||
- fediverse-project.yaml
|
||||
- fediverse-namespaces.yaml
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: nextcloud-cnpg
|
||||
namespace: argocd
|
||||
annotations:
|
||||
argocd.argoproj.io/sync-wave: "0"
|
||||
spec:
|
||||
project: nextcloud
|
||||
source:
|
||||
repoURL: https://code.brunner.ninja/feedc0de/homelab-gitops.git
|
||||
targetRevision: main
|
||||
path: apps/nextcloud-postgresql/cluster
|
||||
destination:
|
||||
server: https://kubernetes.default.svc
|
||||
namespace: nextcloud
|
||||
syncPolicy:
|
||||
automated:
|
||||
enabled: true
|
||||
prune: true
|
||||
selfHeal: true
|
||||
@@ -0,0 +1,19 @@
|
||||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: nextcloud-postgresql
|
||||
namespace: argocd
|
||||
spec:
|
||||
project: nextcloud
|
||||
source:
|
||||
repoURL: https://code.brunner.ninja/feedc0de/homelab-gitops.git
|
||||
targetRevision: main
|
||||
path: apps/nextcloud-postgresql/service
|
||||
destination:
|
||||
server: https://kubernetes.default.svc
|
||||
namespace: nextcloud
|
||||
syncPolicy:
|
||||
automated:
|
||||
enabled: true
|
||||
prune: true
|
||||
selfHeal: true
|
||||
@@ -29,6 +29,8 @@ spec:
|
||||
kind: Deployment
|
||||
- group: apps
|
||||
kind: StatefulSet
|
||||
- group: postgresql.cnpg.io
|
||||
kind: Cluster
|
||||
- group: networking.k8s.io
|
||||
kind: Ingress
|
||||
- group: networking.k8s.io
|
||||
|
||||
Reference in new issue
Block a user