Skip to content

Commit

Permalink
add pdb_master_label_selector to helm chart and example manifests (#2595
Browse files Browse the repository at this point in the history
)

* add pdb_master_label_selector to helm chart and example manifests
  • Loading branch information
FxKu authored Mar 28, 2024
1 parent be28f3a commit 6ddafad
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 12 deletions.
3 changes: 3 additions & 0 deletions charts/postgres-operator/crds/operatorconfigurations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,9 @@ spec:
oauth_token_secret_name:
type: string
default: "postgresql-operator"
pdb_master_label_selector:
type: boolean
default: true
pdb_name_format:
type: string
default: "postgres-{cluster}-pdb"
Expand Down
18 changes: 9 additions & 9 deletions charts/postgres-operator/index.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ entries:
postgres-operator:
- apiVersion: v2
appVersion: 1.11.0
created: "2024-03-18T11:00:15.800881061+01:00"
created: "2024-03-27T16:11:07.44119096+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: e043b8ff810b2e9b9158da5a28db55b1ab371607304f402d157911245974f16f
digest: 3914b5e117bda0834f05c9207f007e2ac372864cf6e86dcc2e1362bbe46c14d9
home: https://github.com/zalando/postgres-operator
keywords:
- postgres
Expand All @@ -25,7 +25,7 @@ entries:
version: 1.11.0
- apiVersion: v2
appVersion: 1.10.1
created: "2024-03-18T11:00:15.798061899+01:00"
created: "2024-03-27T16:11:07.435516407+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: cc3baa41753da92466223d0b334df27e79c882296577b404a8e9071411fcf19c
Expand All @@ -47,7 +47,7 @@ entries:
version: 1.10.1
- apiVersion: v2
appVersion: 1.10.0
created: "2024-03-18T11:00:15.795212886+01:00"
created: "2024-03-27T16:11:07.430181545+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: 60fc5c8059dfed175d14e1034b40997d9c59d33ec8ea158c0597f7228ab04b51
Expand All @@ -69,7 +69,7 @@ entries:
version: 1.10.0
- apiVersion: v2
appVersion: 1.9.0
created: "2024-03-18T11:00:15.812938635+01:00"
created: "2024-03-27T16:11:07.464139323+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: 64df90c898ca591eb3a330328173ffaadfbf9ddd474d8c42ed143edc9e3f4276
Expand All @@ -91,7 +91,7 @@ entries:
version: 1.9.0
- apiVersion: v2
appVersion: 1.8.2
created: "2024-03-18T11:00:15.809490671+01:00"
created: "2024-03-27T16:11:07.459140232+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: f77ffad2e98b72a621e5527015cf607935d3ed688f10ba4b626435acb9631b5b
Expand All @@ -113,7 +113,7 @@ entries:
version: 1.8.2
- apiVersion: v2
appVersion: 1.8.1
created: "2024-03-18T11:00:15.806582514+01:00"
created: "2024-03-27T16:11:07.454211672+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: ee0c3bb6ba72fa4289ba3b1c6060e5b312dd023faba2a61b4cb7d9e5e2cc57a5
Expand All @@ -135,7 +135,7 @@ entries:
version: 1.8.1
- apiVersion: v1
appVersion: 1.8.0
created: "2024-03-18T11:00:15.803722471+01:00"
created: "2024-03-27T16:11:07.449062797+01:00"
description: Postgres Operator creates and manages PostgreSQL clusters running
in Kubernetes
digest: 3ae232cf009e09aa2ad11c171484cd2f1b72e63c59735e58fbe2b6eb842f4c86
Expand All @@ -155,4 +155,4 @@ entries:
urls:
- postgres-operator-1.8.0.tgz
version: 1.8.0
generated: "2024-03-18T11:00:15.778587784+01:00"
generated: "2024-03-27T16:11:07.42441665+01:00"
Binary file modified charts/postgres-operator/postgres-operator-1.11.0.tgz
Binary file not shown.
4 changes: 3 additions & 1 deletion charts/postgres-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,9 @@ configKubernetes:
# namespaced name of the secret containing the OAuth2 token to pass to the teams API
# oauth_token_secret_name: postgresql-operator

# defines the template for PDB (Pod Disruption Budget) names
# toggle if `spilo-role=master` selector should be added to the PDB (Pod Disruption Budget)
pdb_master_label_selector: true
# defines the template for PDB names
pdb_name_format: "postgres-{cluster}-pdb"
# specify the PVC retention policy when scaling down and/or deleting
persistent_volume_claim_retention_policy:
Expand Down
4 changes: 2 additions & 2 deletions docs/reference/operator_parameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ configuration they are grouped under the `kubernetes` key.

* **pdb_master_label_selector**
By default the PDB will match the master role hence preventing nodes to be
drained if the node_readiness_label is not used. This option if set to `false`
will not add the `spilo-role=master` selector to the PDB.
drained if the node_readiness_label is not used. If this option if set to
`false` the `spilo-role=master` selector will not be added to the PDB.

* **enable_finalizers**
By default, a deletion of the Postgresql resource will trigger an event
Expand Down
1 change: 1 addition & 0 deletions manifests/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ data:
patroni_api_check_timeout: "5s"
# password_rotation_interval: "90"
# password_rotation_user_retention: "180"
pdb_master_label_selector: "true"
pdb_name_format: "postgres-{cluster}-pdb"
persistent_volume_claim_retention_policy: "when_deleted:retain,when_scaled:retain"
# pod_antiaffinity_preferred_during_scheduling: "false"
Expand Down
3 changes: 3 additions & 0 deletions manifests/operatorconfiguration.crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,9 @@ spec:
oauth_token_secret_name:
type: string
default: "postgresql-operator"
pdb_master_label_selector:
type: boolean
default: true
pdb_name_format:
type: string
default: "postgres-{cluster}-pdb"
Expand Down
1 change: 1 addition & 0 deletions manifests/postgresql-operator-default-configuration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ configuration:
# status: ready
# node_readiness_label_merge: "OR"
oauth_token_secret_name: postgresql-operator
pdb_master_label_selector: true
pdb_name_format: "postgres-{cluster}-pdb"
persistent_volume_claim_retention_policy:
when_deleted: "retain"
Expand Down

0 comments on commit 6ddafad

Please sign in to comment.