Skip to content

Commit

Permalink
Merge branch 'main' into feature/merged-dragoangel-cluster-prs
Browse files Browse the repository at this point in the history
Signed-off-by: Dmitriy Alekseev <[email protected]>
  • Loading branch information
dragoangel authored Sep 4, 2024
2 parents 4e02190 + eb2f245 commit 5817451
Show file tree
Hide file tree
Showing 8 changed files with 38 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
with:
version: v3.4.0

- uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f # v5.1.1
- uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0
with:
python-version: 3.7

Expand Down
2 changes: 1 addition & 1 deletion charts/cluster/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ name: cluster
description: Deploys and manages a CloudNativePG cluster and its associated resources.
icon: https://raw.githubusercontent.com/cloudnative-pg/artwork/main/cloudnativepg-logo.svg
type: application
version: 0.0.10
version: 0.0.11
sources:
- https://github.com/cloudnative-pg/charts
keywords:
Expand Down
6 changes: 4 additions & 2 deletions charts/cluster/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# cluster

![Version: 0.0.10](https://img.shields.io/badge/Version-0.0.10-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
![Version: 0.0.11](https://img.shields.io/badge/Version-0.0.11-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)

> **Warning**
> ### This chart is under active development.
Expand Down Expand Up @@ -177,7 +177,8 @@ refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentat
| cluster.monitoring.prometheusRule.excludeRules | list | `[]` | Exclude specified rules |
| cluster.postgresGID | int | `26` | The GID of the postgres user inside the image, defaults to 26 |
| cluster.postgresUID | int | `26` | The UID of the postgres user inside the image, defaults to 26 |
| cluster.postgresql | object | `{}` | Configuration of the PostgreSQL server. See: https://cloudnative-pg.io/documentation/current/cloudnative-pg.v1/#postgresql-cnpg-io-v1-PostgresConfiguration |
| cluster.postgresql.parameters | object | `{}` | PostgreSQL configuration options (postgresql.conf) |
| cluster.postgresql.pg_hba | list | `[]` | PostgreSQL Host Based Authentication rules (lines to be appended to the pg_hba.conf file) |
| cluster.primaryUpdateMethod | string | `"switchover"` | 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 restart. |
| cluster.primaryUpdateStrategy | string | `"unsupervised"` | 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) |
| cluster.priorityClassName | string | `""` | |
Expand All @@ -187,6 +188,7 @@ refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentat
| cluster.storage.size | string | `"8Gi"` | |
| cluster.storage.storageClass | string | `""` | |
| cluster.superuserSecret | string | `""` | |
| cluster.walStorage.enabled | bool | `false` | |
| cluster.walStorage.size | string | `"1Gi"` | |
| cluster.walStorage.storageClass | string | `""` | |
| fullnameOverride | string | `""` | Override the full name of the chart |
Expand Down
8 changes: 5 additions & 3 deletions charts/cluster/templates/cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ spec:
storage:
size: {{ .Values.cluster.storage.size }}
storageClass: {{ .Values.cluster.storage.storageClass }}
{{- if .Values.cluster.walStorage }}
{{- if .Values.cluster.walStorage.enabled }}
walStorage:
size: {{ .Values.cluster.walStorage.size }}
storageClass: {{ .Values.cluster.walStorage.storageClass }}
Expand Down Expand Up @@ -65,8 +65,10 @@ spec:
{{- end }}
{{- with .Values.cluster.postgresql }}
parameters:
{{- toYaml . | nindent 6 }}
{{- end }}
{{- toYaml .parameters | nindent 6 }}
pg_hba:
{{- toYaml .pg_hba | nindent 6 }}
{{ end }}

{{- with .Values.cluster.roles }}
managed:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ spec:
postgresql:
parameters:
max_connections: "42"
pg_hba:
- host all 1.2.3.4/32 trust
bootstrap:
initdb:
database: mydb
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ cluster:
size: 256Mi
storageClass: standard
walStorage:
enabled: true
size: 256Mi
storageClass: standard
postgresUID: 1001
Expand Down Expand Up @@ -57,7 +58,10 @@ cluster:
- pg_monitor
- pg_signal_backend
postgresql:
max_connections: "42"
parameters:
max_connections: "42"
pg_hba:
- host all 1.2.3.4/32 trust
initdb:
database: mydb
owner: dante
Expand Down
13 changes: 12 additions & 1 deletion charts/cluster/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,15 @@
"type": "integer"
},
"postgresql": {
"type": "object"
"type": "object",
"properties": {
"parameters": {
"type": "object"
},
"pg_hba": {
"type": "array"
}
}
},
"primaryUpdateMethod": {
"type": "string"
Expand Down Expand Up @@ -342,6 +350,9 @@
"walStorage": {
"type": "object",
"properties": {
"enabled": {
"type": "boolean"
},
"size": {
"type": "string"
},
Expand Down
12 changes: 8 additions & 4 deletions charts/cluster/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ cluster:
storageClass: ""

walStorage:
enabled: false
size: 1Gi
storageClass: ""

Expand Down Expand Up @@ -160,10 +161,13 @@ cluster:
# - name: custom-queries-secret
# key: custom-queries

# -- Configuration of the PostgreSQL server.
# See: https://cloudnative-pg.io/documentation/current/cloudnative-pg.v1/#postgresql-cnpg-io-v1-PostgresConfiguration
postgresql: {}
# max_connections: 300
postgresql:
# -- PostgreSQL configuration options (postgresql.conf)
parameters: {}
# max_connections: 300
# -- PostgreSQL Host Based Authentication rules (lines to be appended to the pg_hba.conf file)
pg_hba: []
# - host all all 10.244.0.0/16 md5

# -- BootstrapInitDB is the configuration of the bootstrap process when initdb is used.
# See: https://cloudnative-pg.io/documentation/current/bootstrap/
Expand Down

0 comments on commit 5817451

Please sign in to comment.