2022-12-13 20:35:35 +00:00
|
|
|
apiVersion: postgresql.cnpg.io/v1
|
|
|
|
kind: Cluster
|
|
|
|
metadata:
|
|
|
|
name: gitea-db
|
|
|
|
namespace: gitea
|
2024-01-16 13:21:09 +00:00
|
|
|
annotations:
|
|
|
|
cnpg.io/skipEmptyWalArchiveCheck: enabled
|
2022-12-13 20:35:35 +00:00
|
|
|
spec:
|
|
|
|
instances: 1
|
|
|
|
imageName: ghcr.io/cloudnative-pg/postgresql:15
|
|
|
|
|
|
|
|
bootstrap:
|
2024-01-16 13:21:09 +00:00
|
|
|
recovery:
|
|
|
|
source: gitea-db
|
2022-12-13 20:35:35 +00:00
|
|
|
|
2023-07-25 19:48:23 +00:00
|
|
|
backup:
|
|
|
|
barmanObjectStore:
|
2024-01-16 13:21:09 +00:00
|
|
|
destinationPath: "s3://forgejo/"
|
|
|
|
endpointURL: "http://s3-minio.s3.svc.cluster.local:9000"
|
2023-07-25 19:48:23 +00:00
|
|
|
s3Credentials:
|
|
|
|
accessKeyId:
|
|
|
|
name: bucket
|
|
|
|
key: accesskey
|
|
|
|
secretAccessKey:
|
|
|
|
name: bucket
|
|
|
|
key: secretkey
|
|
|
|
wal:
|
|
|
|
compression: gzip
|
|
|
|
#encryption: AES256
|
|
|
|
data:
|
|
|
|
compression: gzip
|
|
|
|
#encryption: AES256
|
|
|
|
retentionPolicy: "90d"
|
|
|
|
#
|
2022-12-13 20:35:35 +00:00
|
|
|
resources:
|
|
|
|
requests:
|
|
|
|
memory: "64Mi"
|
|
|
|
cpu: "50m"
|
2024-01-16 14:34:07 +00:00
|
|
|
# limits:
|
|
|
|
# memory: "1Gi"
|
|
|
|
# cpu: "1"
|
2022-12-13 20:35:35 +00:00
|
|
|
|
|
|
|
storage:
|
|
|
|
size: 10Gi
|
|
|
|
|
|
|
|
externalClusters:
|
2023-02-13 15:37:57 +00:00
|
|
|
- name: gitea-db
|
|
|
|
barmanObjectStore:
|
2024-01-16 13:21:09 +00:00
|
|
|
destinationPath: "s3://forgejo/"
|
|
|
|
endpointURL: "http://s3-minio.s3.svc.cluster.local:9000"
|
2023-02-13 15:37:57 +00:00
|
|
|
s3Credentials:
|
|
|
|
accessKeyId:
|
|
|
|
name: bucket
|
|
|
|
key: accesskey
|
|
|
|
secretAccessKey:
|
|
|
|
name: bucket
|
|
|
|
key: secretkey
|
|
|
|
wal:
|
|
|
|
maxParallel: 8
|
2022-12-14 09:15:38 +00:00
|
|
|
---
|
|
|
|
apiVersion: postgresql.cnpg.io/v1
|
|
|
|
kind: ScheduledBackup
|
|
|
|
metadata:
|
|
|
|
name: gitea-db-backup
|
|
|
|
namespace: gitea
|
|
|
|
spec:
|
2022-12-15 17:08:14 +00:00
|
|
|
schedule: "0 0 * * * *"
|
2022-12-14 09:15:38 +00:00
|
|
|
backupOwnerReference: self
|
|
|
|
cluster:
|
|
|
|
name: gitea-db
|