# -- Override the name of the cluster nameOverride: "" # -- Type of the CNPG database. Available types: # * `postgresql` # * `postgis` # * `timescaledb` # * `tensorchord` type: postgresql # -- Cluster mode of operation. Available modes: # * `standalone` - Default mode. Creates new or updates an existing CNPG cluster. # * `recovery` - Same as standalone but creates a cluster from a backup, object store or via pg_basebackup # * `replica` - Create database as a replica from another CNPG cluster mode: standalone cluster: instances: 3 # -- Default image image: repository: ghcr.io/cloudnative-pg/postgresql tag: "17.2-22" pullPolicy: IfNotPresent # -- The UID and GID of the postgres user inside the image postgresUID: 26 postgresGID: 26 # -- Create secret containing credentials of superuser enableSuperuserAccess: false # -- Default storage size walStorage: size: 2Gi storageClass: "" storage: size: 10Gi storageClass: "" # -- Default resources resources: requests: memory: 256Mi cpu: 100m limits: cpu: '1' hugepages-2Mi: 256Mi # -- See: https://cloudnative-pg.io/documentation/current/cloudnative-pg.v1/#postgresql-cnpg-io-v1-AffinityConfiguration affinity: enablePodAntiAffinity: true topologyKey: kubernetes.io/hostname additionalLabels: {} annotations: {} priorityClassName: "" # -- Method to follow to upgrade the primary server during a rolling update procedure, after all replicas have been # successfully updated. It can be switchover (default) or in-place (restart). primaryUpdateMethod: switchover # -- Strategy to follow to upgrade the primary server during a rolling update procedure, after all replicas have been # successfully updated: it can be automated (unsupervised - default) or manual (supervised) primaryUpdateStrategy: unsupervised logLevel: "info" # -- Enable default monitoring and alert rules monitoring: enabled: false podMonitor: enabled: true prometheusRule: enabled: false enableDefaultRules: true excludeRules: [] # -- Parameters to be set for the database itself # See: https://cloudnative-pg.io/documentation/current/cloudnative-pg.v1/#postgresql-cnpg-io-v1-PostgresConfiguration postgresql: parameters: shared_buffers: 128MB max_slot_wal_keep_size: 2000MB hot_standby_feedback: "on" shared_preload_libraries: [] # -- Bootstrap is the configuration of the bootstrap process when initdb is used. # See: https://cloudnative-pg.io/documentation/current/bootstrap/ # See: https://cloudnative-pg.io/documentation/current/cloudnative-pg.v1/#postgresql-cnpg-io-v1-bootstrapinitdb bootstrap: # -- Example values # database: app # owner: app # secret: "" # Name of the secret containing the initial credentials for the owner of the user database. If empty a new secret will be created from scratch # postInitApplicationSQL: # - CREATE TABLE IF NOT EXISTS example; initdb: {} # -- Recovery settings when booting cluster from external cluster recovery: # -- Point in time recovery target in RFC3339 format pitrTarget: time: "" # -- S3 https endpoint and the s3:// path endpointURL: "" destinationPath: "" # -- Specifies secret that contains a CA bundle to validate a privately signed certificate, should contain the key ca-bundle.crt endpointCA: "" # -- Specifies secret that contains S3 credentials, should contain the keys ACCESS_KEY_ID and ACCESS_SECRET_KEY endpointCredentials: "" # -- Generate external cluster name, uses: {{ .Release.Name }}postgresql--cluster-backup-index-{{ .Values.recovery.recoveryIndex }} recoveryIndex: 1 # -- Name of the recovery cluster in the object store, defaults to "cluster.name" recoveryServerName: "" # -- Name of the recovery cluster in the object store, defaults to ".Release.Name" recoveryInstanceName: "" wal: # -- WAL compression method. One of `` (for no compression), `gzip`, `bzip2` or `snappy`. compression: snappy # -- Whether to instruct the storage provider to encrypt WAL files. One of `` (use the storage container default), `AES256` or `aws:kms`. encryption: "" # -- Number of WAL files to be archived or restored in parallel. maxParallel: 1 data: # -- Data compression method. One of `` (for no compression), `gzip`, `bzip2` or `snappy`. compression: snappy # -- Whether to instruct the storage provider to encrypt data files. One of `` (use the storage container default), `AES256` or `aws:kms`. encryption: "" # -- Number of data files to be archived or restored in parallel. jobs: 1 replica: # -- See [here](https://cloudnative-pg.io/documentation/current/database_import/) for different import types # * `microservice` - Single database import as expected from cnpg clusters # * `monolith` - Import multiple databases and roles importType: microservice # -- If type microservice only one database is allowed, default is app as standard in cnpg clusters importDatabases: - app # -- If type microservice no roles are imported and ignored importRoles: [] # -- If import type is monolith postImportApplicationSQL is not supported and ignored postImportApplicationSQL: [] # -- External cluster connection, password specifies a secret name and the key containing the password value externalCluster: connectionParameters: host: postgresql user: app dbname: app password: name: postgresql key: password backup: enabled: false # -- S3 endpoint starting with "https://" endpointURL: "" # -- S3 path starting with "s3://" destinationPath: "" # -- Specifies secret that contains a CA bundle to validate a privately signed certificate, should contain the key ca-bundle.crt endpointCA: "" # -- Specifies secret that contains S3 credentials, should contain the keys ACCESS_KEY_ID and ACCESS_SECRET_KEY endpointCredentials: "" # -- Generate external cluster name, creates: postgresql-{{ .Release.Name }}-cluster-backup-index-{{ .Values.backups.backupIndex }}" backupIndex: 1 # -- Name of the backup cluster in the object store, defaults to "cluster.name" backupName: "" # -- Tags to add to backups. Add in key value beneath the type. tags: backupRetentionPolicy: "" historyTags: backupRetentionPolicy: "" wal: # -- WAL compression method. One of `` (for no compression), `gzip`, `bzip2` or `snappy`. compression: snappy # -- Whether to instruct the storage provider to encrypt WAL files. One of `` (use the storage container default), `AES256` or `aws:kms`. encryption: "" # -- Number of WAL files to be archived or restored in parallel. maxParallel: 1 data: # -- Data compression method. One of `` (for no compression), `gzip`, `bzip2` or `snappy`. compression: snappy # -- Whether to instruct the storage provider to encrypt data files. One of `` (use the storage container default), `AES256` or `aws:kms`. encryption: "" # -- Number of data files to be archived or restored in parallel. jobs: 1 # -- Retention policy for backups retentionPolicy: "7d" # -- Scheduled backup in cron format schedule: "0 0 */3 * *"