Repository navigation
Conversation
|
/test |
|
❗ By default, the pull request is configured to backport to all release branches.
|
|
@armru, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/22718198409 |
|
@mnencia probably this should be tested with a pg_hba config like the one here https://github.com/cloudnative-pg/postgres-keycloak-oauth-validator?tab=readme-ov-file#example-cloudnativepg-configuration |
|
There is a problem with the markdown code for |
|
I created the apiVersion: postgresql.cnpg.io/v1
kind: Cluster
metadata:
name: angus
spec:
instances: 3
podSelectorRefs:
- name: marshall-pooler
selector:
matchLabels:
cnpg.io/podRole: pooler
cnpg.io/cluster: angus
cnpg.io/poolerName: marshall
postgresql:
pg_hba:
- "hostssl all all ${podselector:marshall-pooler} scram-sha-256"
- "host all all all reject"
storage:
size: 1Gi
---
apiVersion: postgresql.cnpg.io/v1
kind: Pooler
metadata:
name: marshall
spec:
cluster:
name: angus
instances: 3
type: rw
pgbouncer:
poolMode: session
parameters:
max_client_conn: "1000"
default_pool_size: "10"The cluster defines the I then create these two simple jobs with apiVersion: batch/v1
kind: Job
metadata:
name: marshall-pgbench
spec:
template:
spec:
containers:
- args:
- -i
command:
- pgbench
env:
- name: PGHOST
value: marshall
- name: PGDATABASE
value: app
- name: PGPORT
value: "5432"
- name: PGUSER
valueFrom:
secretKeyRef:
key: username
name: angus-app
- name: PGPASSWORD
valueFrom:
secretKeyRef:
key: password
name: angus-app
image: ghcr.io/cloudnative-pg/postgresql:18.1-system-trixie
name: pgbench
restartPolicy: Never
---
apiVersion: batch/v1
kind: Job
metadata:
name: angus-pgbench
spec:
template:
spec:
containers:
- args:
- -i
command:
- pgbench
env:
- name: PGHOST
value: angus-rw
- name: PGDATABASE
value: app
- name: PGPORT
value: "5432"
- name: PGUSER
valueFrom:
secretKeyRef:
key: username
name: angus-app
- name: PGPASSWORD
valueFrom:
secretKeyRef:
key: password
name: angus-app
image: ghcr.io/cloudnative-pg/postgresql:18.1-system-trixie
name: pgbench
restartPolicy: NeverThis is the result: $ kubectl get pods
NAME READY STATUS RESTARTS AGE
angus-1 1/1 Running 0 17m
angus-2 1/1 Running 0 17m
angus-3 1/1 Running 0 14m
angus-pgbench-7q56c 0/1 Error 0 7s
csi-hostpathplugin-0 8/8 Running 0 6h21m
marshall-6796d674ff-czmkj 1/1 Running 0 17m
marshall-6796d674ff-gzmf9 1/1 Running 0 17m
marshall-6796d674ff-wmlwk 1/1 Running 0 17m
marshall-pgbench-blm7c 0/1 Completed 0 7s
$ kubectl logs jobs/angus-pgbench
Found 2 pods, using pod/angus-pgbench-7q56c
pgbench: error: connection to server at "angus-rw" (10.96.155.110), port 5432 failed: FATAL: pg_hba.conf rejects connection for host "10.244.1.20", user "app", database "app", SSL encryption
connection to server at "angus-rw" (10.96.155.110), port 5432 failed: FATAL: pg_hba.conf rejects connection for host "10.244.1.20", user "app", database "app", no encryption
pgbench: error: could not create connection for initialization
$ kubectl logs jobs/marshall-pgbench
dropping old tables...
creating tables...
generating data (client-side)...
100000 of 100000 tuples (100%) of pgbench_accounts done (elapsed 0.01 s, remaining 0.00 s)
vacuuming...
creating primary keys...
done in 0.10 s (drop tables 0.03 s, create tables 0.00 s, client-side generate 0.03 s, vacuum 0.02 s, primary keys 0.01 s).The |
|
Moreover, the podSelectorRefs:
- ips:
- 10.244.1.16
- 10.244.2.16
- 10.244.3.24
name: poolerIf I delete a pgbouncer pod, a new one is recreated with a different IP and the status is immediately updated: podSelectorRefs:
- ips:
- 10.244.1.16
- 10.244.2.20
- 10.244.3.24
name: pooler |
podSelectorRefs for dynamic pg_hba address resolution
Although I have not tested the validator, I have introduced the row in the
The dual-stack issue should be addressed globally, as it is not tied to this specific feature (as far as I understand). There is an ongoing discussion about this (#7116), but my response aligns with what I’ve been saying: considering everything, I believe there are more critical areas for the project to focus on at this stage, particularly regarding technical debt. I believe the feature, as it stands, provides significant value and should be considered a major feature for version 1.29. However, it would be great to get your review if you have time. |
b091b17 to
1589982
Compare
|
/test |
|
@mnencia, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/22861590448 |
Enable dynamic pod IP resolution in pg_hba rules via named label
selectors. Users can define podSelectorRefs with label selectors
that match application pods, then reference them in pg_hba rules
using ${podselector:<name>} syntax. The operator resolves matching
pod IPs and the instance manager expands ${podselector:<name>}
tokens into one pg_hba line per IP with /32 (IPv4) or /128 (IPv6)
masks.
Signed-off-by: Armando Ruocco <[email protected]>
Co-authored-by: Leonardo Cecchi <[email protected]>
Signed-off-by: Gabriele Bartolini <[email protected]>
Signed-off-by: Gabriele Bartolini <[email protected]>
Signed-off-by: Gabriele Bartolini <[email protected]>
Signed-off-by: Gabriele Bartolini <[email protected]>
Signed-off-by: Marco Nenciarini <[email protected]>
Signed-off-by: Marco Nenciarini <[email protected]>
Add list-type markers to status field for consistent SSA behavior, detect duplicate selector names in the webhook, fix documentation inaccuracies and clarify code comments. Signed-off-by: Marco Nenciarini <[email protected]>
Signed-off-by: Marco Nenciarini <[email protected]>
Add tests for dual-stack pods, multiple selectors, pending pods without IPs, label and deletion timestamp predicate transitions, mixed IPv4/IPv6 HBA expansion, duplicate names, invalid label selectors, and multiple podselector references per line. Assisted-by: Claude Opus 4.6 Signed-off-by: Marco Nenciarini <[email protected]>
Replace ensureCIDR with hostCIDR using net.IPNet for proper CIDR formatting and IPv6 address normalization. Signed-off-by: Marco Nenciarini <[email protected]>
Signed-off-by: Marco Nenciarini <[email protected]>
|
/test |
|
@mnencia, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/22873766938 |
Clarify actor attribution between operator and instance manager, remove duplicate zero-matches bullet already covered by the warning admonition, tone down "real-time" wording, drop unrelated max_worker_processes from the sample, and remove dead slices.Sort call from the e2e test. Signed-off-by: Marco Nenciarini <[email protected]>
This PR contains the following updates: | Package | Update | Change | |---|---|---| | [cloudnative-pg](https://cloudnative-pg.io) ([source](https://github.com/cloudnative-pg/charts)) | minor | `0.27.1` → `0.28.0` | | [cloudnative-pg/cloudnative-pg](https://github.com/cloudnative-pg/cloudnative-pg) | minor | `1.28.1` → `1.29.0` | --- ### Release Notes <details> <summary>cloudnative-pg/charts (cloudnative-pg)</summary> ### [`v0.28.0`](https://github.com/cloudnative-pg/charts/releases/tag/cloudnative-pg-v0.28.0) [Compare Source](cloudnative-pg/charts@cloudnative-pg-v0.27.1...cloudnative-pg-v0.28.0) CloudNativePG Operator Helm Chart #### What's Changed - fix(security): harden GitHub Actions workflows against expression injection by [@​mnencia](https://github.com/mnencia) in [#​823](cloudnative-pg/charts#823) - feat(monitoring): add support for custom PodMonitor by [@​Dashing-Nelson](https://github.com/Dashing-Nelson) in [#​724](cloudnative-pg/charts#724) - Release cloudnative-pg-v0.28.0 by [@​cnpg-bot](https://github.com/cnpg-bot) in [#​845](cloudnative-pg/charts#845) #### New Contributors - [@​Dashing-Nelson](https://github.com/Dashing-Nelson) made their first contribution in [#​724](cloudnative-pg/charts#724) **Full Changelog**: <cloudnative-pg/charts@cluster-v0.6.0...cloudnative-pg-v0.28.0> </details> <details> <summary>cloudnative-pg/cloudnative-pg (cloudnative-pg/cloudnative-pg)</summary> ### [`v1.29.0`](https://github.com/cloudnative-pg/cloudnative-pg/releases/tag/v1.29.0) [Compare Source](cloudnative-pg/cloudnative-pg@v1.28.2...v1.29.0-rc1) **Release date:** Mar 31, 2026 ##### Important changes - Updated the deprecation notice for native (in-tree) Barman Cloud support to reflect that it will now be removed in CloudNativePG 1.30.0, rather than 1.29.0. Users are still encouraged to migrate to the Barman Cloud Plugin. ([#​10167](cloudnative-pg/cloudnative-pg#10167)) <!-- 1.28 1.27 --> ##### Features - **PostgreSQL extensions in image catalogs**: extended the `ImageCatalog` functionality to support PostgreSQL extensions. This allows users to define and manage extension-specific images within a catalog, simplifying the deployment of customized PostgreSQL builds. ([#​9781](cloudnative-pg/cloudnative-pg#9781)) - **Dynamic network access control via pod selectors**: introduced the declarative definition of `podSelectorRefs` to manage `pg_hba.conf` rules dynamically. By using label selectors to identify client pods, the operator automatically resolves their ephemeral IP addresses and updates the PostgreSQL host-based authentication rules accordingly. This ensures that only authorized workloads in the same namespace can connect to the database, eliminating the need for manual IP management or static CIDR ranges. ([#​10148](cloudnative-pg/cloudnative-pg#10148)) - **Shared `ServiceAccount` support**: added an optional `serviceAccountName` field to both `Cluster` and `Pooler` specifications. This allows multiple resources to share a pre-existing ServiceAccount, facilitating one-time IAM configurations (such as AWS IRSA, GCP Workload Identity, or Azure Workload Identity) across all clusters and poolers. Contributed by [@​bozkayasalihx](https://github.com/bozkayasalihx). ([#​9287](cloudnative-pg/cloudnative-pg#9287)) ##### Enhancements - Improved the `Pooler` CRD with support for granular configuration of TLS cipher suites and minimum/maximum TLS versions. This enables administrators to meet strict security compliance requirements for pooler-to-client and pooler-to-server connections. Contributed by [@​alex1989hu](https://github.com/alex1989hu). ([#​9571](cloudnative-pg/cloudnative-pg#9571)) <!-- 1.28 1.27 1.25 --> - Improved the reliability of major upgrades by setting `BackoffLimit=0` on the upgrade job, preventing unnecessary retries of a failed `pg_upgrade`. The operator now automatically deletes the failed job when a user reverts the container image, allowing the cluster to restart gracefully on the original version. ([#​10104](cloudnative-pg/cloudnative-pg#10104), [#​10298](cloudnative-pg/cloudnative-pg#10298)) <!-- 1.28 1.27 --> - Improved the operator's observability by emitting native Kubernetes events during key phases of the reconciliation loop, providing visibility into the operator's decision-making process and the lifecycle of managed resources directly through `kubectl get events`. ([#​10040](cloudnative-pg/cloudnative-pg#10040)) - Extended support for the `cnpg.io/reconciliationDisabled` annotation on Backup resources. This allows administrators to temporarily freeze the operator's reconciliation logic for specific backup objects. Contributed by [@​GabriFedi97](https://github.com/GabriFedi97). ([#​10020](cloudnative-pg/cloudnative-pg#10020)) - Added a `bin_path` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows extensions to specify directory paths for external binaries, which are automatically appended to the `PATH` environment variable of the Postgres process. ([#​10250](cloudnative-pg/cloudnative-pg#10250)) - Added an `env` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows cluster administrators to define custom environment variables for the Postgres process. This field supports the `${image_root}` placeholder to dynamically resolve to the extension's absolute mount path. ([#​10375](cloudnative-pg/cloudnative-pg#10375)) - Implemented a finalizer for plugins to ensure that resources managed by a plugin are gracefully cleaned up when the corresponding service is deleted. ([#​9560](cloudnative-pg/cloudnative-pg#9560)) - Improved role management by verifying the instance is the primary before each reconciliation cycle, avoiding unnecessary reconciliation attempts and spurious error messages on read-only replicas. ([#​9971](cloudnative-pg/cloudnative-pg#9971)) <!-- 1.28 1.27 1.25 --> - The operator now honors the `primaryUpdateMethod` when adding new PVCs to a cluster, ensuring that the rollout strategy (e.g., switchover vs. restart) is respected during storage expansion or additions. ([#​9720](cloudnative-pg/cloudnative-pg#9720)) <!-- 1.28 1.27 --> - Refined the `alpha.cnpg.io/unrecoverable` annotation logic to allow it to function even on pods that have not yet reached the `Ready` state, facilitating the recovery of stuck instances. ([#​9968](cloudnative-pg/cloudnative-pg#9968)) <!-- 1.28 --> - Introduced a "Terminal Error" phase for backups that encounter unrecoverable issues (such as invalid credentials or non-existent cloud buckets). This ensures the operator stops retrying doomed operations, preventing resource exhaustion and providing immediate, clear feedback in the status. ([#​9353](cloudnative-pg/cloudnative-pg#9353)) - Improved monitoring of long-running backups by introducing `reconciliationStartedAt` and `reconciliationTerminatedAt` fields to the `Backup` status. This change separates the operator's internal lifecycle from the actual backup tool's execution timing (`startedAt`/`stoppedAt`), allowing users to track when the operator begins processing a request. ([#​9351](cloudnative-pg/cloudnative-pg#9351)) - Added a `Pending` phase to the `Backup` status to explicitly indicate when a backup is queued and waiting for an available worker or instance availability. ([#​9364](cloudnative-pg/cloudnative-pg#9364)) ##### Security and Supply Chain - **Security best practices integration**: integrated the OpenSSF baseline scanner and added a `SECURITY-INSIGHTS.yaml` file to the repository to align with industry-standard security reporting. ([#​10054](cloudnative-pg/cloudnative-pg#10054), <!-- 1.28 1.27 1.25 --> [#​10062](cloudnative-pg/cloudnative-pg#10062)) <!-- 1.28 1.27 1.25 --> - **SLSA provenance and SBOMs**: added SLSA (Supply-chain Levels for Software Artifacts) provenance to release binaries and container images. Additionally, enabled Software Bill of Materials (SBOM) generation within the GoReleaser pipeline for improved dependency transparency. ([#​10048](cloudnative-pg/cloudnative-pg#10048), <!-- 1.28 1.27 1.25 --> [#​10074](cloudnative-pg/cloudnative-pg#10074)) <!-- 1.28 1.27 1.25 --> - **Password leak prevention**: fixed a potential security risk where PostgreSQL could leak role passwords in the logs during specific reconciliation phases. ([#​9950](cloudnative-pg/cloudnative-pg#9950)) <!-- 1.28 1.27 1.25 --> ##### Changes - Updated the default PostgreSQL version to 18.3 (image `18.3-system-trixie`). ([#​10090](cloudnative-pg/cloudnative-pg#10090)) <!-- 1.28 1.27 1.25 --> ##### Fixes - Fixed a deadlock during operator upgrades affecting clusters using synchronous replication, where pods running the old and new operator versions computed different PostgreSQL configuration hashes, causing the uniformity check to block indefinitely and preventing both rolling updates and in-place upgrades from proceeding. ([#​10342](cloudnative-pg/cloudnative-pg#10342)) <!-- 1.28 --> - Fixed an issue where fencing annotations could not be processed when the WAL disk was full, because the disk space check blocked the instance manager from starting. The check is now performed later in the lifecycle loop, after fencing is evaluated. ([#​10302](cloudnative-pg/cloudnative-pg#10302)) <!-- 1.28 1.27 --> - Fixed an issue where replicas would get stuck in a `Pending` state if the `VolumeSnapshot` used for the initial bootstrap had been deleted. The operator now validates snapshot existence before use; if a snapshot is missing, it attempts to use the next available candidate or falls back to `pg_basebackup`. ([#​10192](cloudnative-pg/cloudnative-pg#10192)) <!-- 1.28 1.27 1.25 --> - Prevented the "supervised primary" rollout strategy from consuming all available rollout slots, which previously caused delays in scheduled updates. Contributed by [@​ermakov-oleg](https://github.com/ermakov-oleg). ([#​9977](cloudnative-pg/cloudnative-pg#9977)) <!-- 1.28 1.27 1.25 --> - Fixed an issue where certain hot-standby parameter changes were not being correctly applied to replica clusters. ([#​9952](cloudnative-pg/cloudnative-pg#9952)) <!-- 1.28 1.27 1.25 --> - Fixed a bug in the CNPG-I reconciler hook that could lead to skipping subsequent plugins when a "continue" result was returned. Contributed by [@​sharifmshaker](https://github.com/sharifmshaker). ([#​9978](cloudnative-pg/cloudnative-pg#9978)) <!-- 1.28 1.27 --> - Fixed a deadlock scenario that occurred when attempting to resize a filesystem on a PVC that was not currently attached to a Pod. Contributed by [@​jmealo](https://github.com/jmealo). ([#​9981](cloudnative-pg/cloudnative-pg#9981)) <!-- 1.28 1.27 --> - Fixed webhook validation of bootstrap recovery sources to accept external clusters configured with `ConnectionParameters` (for `pg_basebackup`-based recovery). Previously, these were incorrectly rejected unless a Barman object store or CNPG-i plugin was also configured. ([#​10268](cloudnative-pg/cloudnative-pg#10268)) <!-- 1.28 1.27 1.25 --> - Volume names for extensions and tablespaces are now prefixed to avoid naming collisions with standard cluster volumes. ([#​9973](cloudnative-pg/cloudnative-pg#9973)) <!-- 1.28 1.27 --> - When hibernating a non-healthy cluster, the operator now reports a `WaitingForHealthy` condition, making the deferred hibernation state visible through `cnpg status`. ([#​10193](cloudnative-pg/cloudnative-pg#10193)) <!-- 1.28 1.27 1.25 --> - Fixed fencing to work correctly even when the target pod does not exist. Fencing operates on a cluster-level annotation and should not depend on pod existence; instance name validation is now performed only in the `cnpg fencing on` command. ([#​10035](cloudnative-pg/cloudnative-pg#10035)) <!-- 1.28 1.27 1.25 --> - Fixed the cluster and pooler service reconcilers to correctly handle changes to all spec fields when using the patch update strategy. The reconciler now uses RFC 7386 JSON Merge Patching, preventing cloud-provider-set fields (such as `loadBalancerClass`) from being inadvertently removed. ([#​10190](cloudnative-pg/cloudnative-pg#10190), [#​10311](cloudnative-pg/cloudnative-pg#10311)) <!-- 1.28 1.27 1.25 --> - Fixed a race condition in the deprecated in-tree Barman Cloud backup implementation affecting parallel WAL restore, where prefetched files could be read while still being downloaded, causing PostgreSQL recovery to fail with "invalid checkpoint record" errors. ([#​10285](cloudnative-pg/cloudnative-pg#10285)) <!-- 1.28 1.27 1.25 --> - Fixed the timeline history file validation to also apply to plugin-based WAL restore. Previously, the protection introduced in [#​9650](cloudnative-pg/cloudnative-pg#9650) only covered in-tree restores, allowing plugins to bypass the check and download future timeline history files, causing timeline mismatch errors on replicas. ([#​9849](cloudnative-pg/cloudnative-pg#9849)) <!-- 1.28 1.27 1.25 --> - `cnpg` plugin: - The cnpg plugin now correctly propagates ImagePullSecrets to the `pgbench` Job pod template. ([#​10174](cloudnative-pg/cloudnative-pg#10174)) <!-- 1.28 1.27 1.25 --> ##### Supported versions - Kubernetes 1.35, 1.34, and 1.33 - PostgreSQL 18, 17, 16, 15, and 14 - PostgreSQL 18.3 is the default image - [PostgreSQL 14 support ends on November 12, 2026](https://www.postgresql.org/support/versioning/) ### [`v1.28.2`](https://github.com/cloudnative-pg/cloudnative-pg/releases/tag/v1.28.2) [Compare Source](cloudnative-pg/cloudnative-pg@v1.28.1...v1.28.2) **Release date:** Mar 31, 2026 ##### Important changes - Updated the deprecation notice for native (in-tree) Barman Cloud support to reflect that it will now be removed in CloudNativePG 1.30.0, rather than 1.29.0. Users are still encouraged to migrate to the Barman Cloud Plugin. ([#​10167](cloudnative-pg/cloudnative-pg#10167)) <!-- 1.28 1.27 --> ##### Enhancements - Improved the `Pooler` CRD with support for granular configuration of TLS cipher suites and minimum/maximum TLS versions. This enables administrators to meet strict security compliance requirements for pooler-to-client and pooler-to-server connections. Contributed by [@​alex1989hu](https://github.com/alex1989hu). ([#​9571](cloudnative-pg/cloudnative-pg#9571)) <!-- 1.28 1.27 1.25 --> - Improved the reliability of major upgrades by setting `BackoffLimit=0` on the upgrade job, preventing unnecessary retries of a failed `pg_upgrade`. The operator now automatically deletes the failed job when a user reverts the container image, allowing the cluster to restart gracefully on the original version. ([#​10104](cloudnative-pg/cloudnative-pg#10104), [#​10298](cloudnative-pg/cloudnative-pg#10298)) <!-- 1.28 1.27 --> - Improved role management by verifying the instance is the primary before each reconciliation cycle, avoiding unnecessary reconciliation attempts and spurious error messages on read-only replicas. ([#​9971](cloudnative-pg/cloudnative-pg#9971)) <!-- 1.28 1.27 1.25 --> - Extended the CRD schemas for `Cluster`, `ImageCatalog`, and `ClusterImageCatalog` to accept the `extensions`, `bin_path`, and `env` fields introduced in 1.29. The operator ignores these fields on older versions, but accepting them in the schema allows users to share a single manifest across clusters running different CNPG versions. ([#​10131](cloudnative-pg/cloudnative-pg#10131), [#​10387](cloudnative-pg/cloudnative-pg#10387)) <!-- 1.28 1.27 --> - The operator now honors the `primaryUpdateMethod` when adding new PVCs to a cluster, ensuring that the rollout strategy (e.g., switchover vs. restart) is respected during storage expansion or additions. ([#​9720](cloudnative-pg/cloudnative-pg#9720)) <!-- 1.28 1.27 --> - Refined the `alpha.cnpg.io/unrecoverable` annotation logic to allow it to function even on pods that have not yet reached the `Ready` state, facilitating the recovery of stuck instances. ([#​9968](cloudnative-pg/cloudnative-pg#9968)) <!-- 1.28 --> ##### Security and Supply Chain - **Security best practices integration**: integrated the OpenSSF baseline scanner and added a `SECURITY-INSIGHTS.yaml` file to the repository to align with industry-standard security reporting. ([#​10054](cloudnative-pg/cloudnative-pg#10054), <!-- 1.28 1.27 1.25 --> [#​10062](cloudnative-pg/cloudnative-pg#10062)) <!-- 1.28 1.27 1.25 --> - **SLSA provenance and SBOMs**: added SLSA (Supply-chain Levels for Software Artifacts) provenance to release binaries and container images. Additionally, enabled Software Bill of Materials (SBOM) generation within the GoReleaser pipeline for improved dependency transparency. ([#​10048](cloudnative-pg/cloudnative-pg#10048), <!-- 1.28 1.27 1.25 --> [#​10074](cloudnative-pg/cloudnative-pg#10074)) <!-- 1.28 1.27 1.25 --> - **Password leak prevention**: fixed a potential security risk where PostgreSQL could leak role passwords in the logs during specific reconciliation phases. ([#​9950](cloudnative-pg/cloudnative-pg#9950)) <!-- 1.28 1.27 1.25 --> ##### Changes - Updated the default PostgreSQL version to 18.3 (image `18.3-system-trixie`). ([#​10090](cloudnative-pg/cloudnative-pg#10090)) <!-- 1.28 1.27 1.25 --> ##### Fixes - Fixed a deadlock during operator upgrades affecting clusters using synchronous replication, where pods running the old and new operator versions computed different PostgreSQL configuration hashes, causing the uniformity check to block indefinitely and preventing both rolling updates and in-place upgrades from proceeding. ([#​10342](cloudnative-pg/cloudnative-pg#10342)) <!-- 1.28 --> - Fixed an issue where fencing annotations could not be processed when the WAL disk was full, because the disk space check blocked the instance manager from starting. The check is now performed later in the lifecycle loop, after fencing is evaluated. ([#​10302](cloudnative-pg/cloudnative-pg#10302)) <!-- 1.28 1.27 --> - Fixed an issue where replicas would get stuck in a `Pending` state if the `VolumeSnapshot` used for the initial bootstrap had been deleted. The operator now validates snapshot existence before use; if a snapshot is missing, it attempts to use the next available candidate or falls back to `pg_basebackup`. ([#​10192](cloudnative-pg/cloudnative-pg#10192)) <!-- 1.28 1.27 1.25 --> - Prevented the "supervised primary" rollout strategy from consuming all available rollout slots, which previously caused delays in scheduled updates. Contributed by [@​ermakov-oleg](https://github.com/ermakov-oleg). ([#​9977](cloudnative-pg/cloudnative-pg#9977)) <!-- 1.28 1.27 1.25 --> - Fixed an issue where certain hot-standby parameter changes were not being correctly applied to replica clusters. ([#​9952](cloudnative-pg/cloudnative-pg#9952)) <!-- 1.28 1.27 1.25 --> - Fixed a bug in the CNPG-I reconciler hook that could lead to skipping subsequent plugins when a "continue" result was returned. Contributed by [@​sharifmshaker](https://github.com/sharifmshaker). ([#​9978](cloudnative-pg/cloudnative-pg#9978)) <!-- 1.28 1.27 --> - Fixed a deadlock scenario that occurred when attempting to resize a filesystem on a PVC that was not currently attached to a Pod. Contributed by [@​jmealo](https://github.com/jmealo). ([#​9981](cloudnative-pg/cloudnative-pg#9981)) <!-- 1.28 1.27 --> - Fixed webhook validation of bootstrap recovery sources to accept external clusters configured with `ConnectionParameters` (for `pg_basebackup`-based recovery). Previously, these were incorrectly rejected unless a Barman object store or CNPG-i plugin was also configured. ([#​10268](cloudnative-pg/cloudnative-pg#10268)) <!-- 1.28 1.27 1.25 --> - Volume names for extensions and tablespaces are now prefixed to avoid naming collisions with standard cluster volumes. ([#​9973](cloudnative-pg/cloudnative-pg#9973)) <!-- 1.28 1.27 --> - When hibernating a non-healthy cluster, the operator now reports a `WaitingForHealthy` condition, making the deferred hibernation state visible through `cnpg status`. ([#​10193](cloudnative-pg/cloudnative-pg#10193)) <!-- 1.28 1.27 1.25 --> - Fixed fencing to work correctly even when the target pod does not exist. Fencing operates on a cluster-level annotation and should not depend on pod existence; instance name validation is now performed only in the `cnpg fencing on` command. ([#​10035](cloudnative-pg/cloudnative-pg#10035)) <!-- 1.28 1.27 1.25 --> - Fixed the cluster and pooler service reconcilers to correctly handle changes to all spec fields when using the patch update strategy. The reconciler now uses RFC 7386 JSON Merge Patching, preventing cloud-provider-set fields (such as `loadBalancerClass`) from being inadvertently removed. ([#​10190](cloudnative-pg/cloudnative-pg#10190), [#​10311](cloudnative-pg/cloudnative-pg#10311)) <!-- 1.28 1.27 1.25 --> - Fixed a race condition in the deprecated in-tree Barman Cloud backup implementation affecting parallel WAL restore, where prefetched files could be read while still being downloaded, causing PostgreSQL recovery to fail with "invalid checkpoint record" errors. ([#​10285](cloudnative-pg/cloudnative-pg#10285)) <!-- 1.28 1.27 1.25 --> - Fixed the timeline history file validation to also apply to plugin-based WAL restore. Previously, the protection introduced in [#​9650](cloudnative-pg/cloudnative-pg#9650) only covered in-tree restores, allowing plugins to bypass the check and download future timeline history files, causing timeline mismatch errors on replicas. ([#​9849](cloudnative-pg/cloudnative-pg#9849)) <!-- 1.28 1.27 1.25 --> - `cnpg` plugin: - The cnpg plugin now correctly propagates ImagePullSecrets to the `pgbench` Job pod template. ([#​10174](cloudnative-pg/cloudnative-pg#10174)) <!-- 1.28 1.27 1.25 --> </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4xMDIuNCIsInVwZGF0ZWRJblZlciI6IjQzLjEwMi42IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJoZWxtIl19--> Reviewed-on: https://gitea.alexlebens.dev/alexlebens/infrastructure/pulls/5367 Co-authored-by: Renovate Bot <[email protected]> Co-committed-by: Renovate Bot <[email protected]>
##### [\`v1.29.0\`](https://github.com/cloudnative-pg/cloudnative-pg/releases/tag/v1.29.0) **Release date:** Mar 31, 2026 ##### Important changes - Updated the deprecation notice for native (in-tree) Barman Cloud support to reflect that it will now be removed in CloudNativePG 1.30.0, rather than 1.29.0. Users are still encouraged to migrate to the Barman Cloud Plugin. ([#10167](cloudnative-pg/cloudnative-pg#10167)) <!-- 1.28 1.27 --> ##### Features - **PostgreSQL extensions in image catalogs**: extended the `ImageCatalog` functionality to support PostgreSQL extensions. This allows users to define and manage extension-specific images within a catalog, simplifying the deployment of customized PostgreSQL builds. ([#9781](cloudnative-pg/cloudnative-pg#9781)) - **Dynamic network access control via pod selectors**: introduced the declarative definition of `podSelectorRefs` to manage `pg_hba.conf` rules dynamically. By using label selectors to identify client pods, the operator automatically resolves their ephemeral IP addresses and updates the PostgreSQL host-based authentication rules accordingly. This ensures that only authorized workloads in the same namespace can connect to the database, eliminating the need for manual IP management or static CIDR ranges. ([#10148](cloudnative-pg/cloudnative-pg#10148)) - **Shared `ServiceAccount` support**: added an optional `serviceAccountName` field to both `Cluster` and `Pooler` specifications. This allows multiple resources to share a pre-existing ServiceAccount, facilitating one-time IAM configurations (such as AWS IRSA, GCP Workload Identity, or Azure Workload Identity) across all clusters and poolers. Contributed by [@bozkayasalihx](https://github.com/bozkayasalihx). ([#9287](cloudnative-pg/cloudnative-pg#9287)) ##### Enhancements - Improved the `Pooler` CRD with support for granular configuration of TLS cipher suites and minimum/maximum TLS versions. This enables administrators to meet strict security compliance requirements for pooler-to-client and pooler-to-server connections. Contributed by [@alex1989hu](https://github.com/alex1989hu). ([#9571](cloudnative-pg/cloudnative-pg#9571)) <!-- 1.28 1.27 1.25 --> - Improved the reliability of major upgrades by setting `BackoffLimit=0` on the upgrade job, preventing unnecessary retries of a failed `pg_upgrade`. The operator now automatically deletes the failed job when a user reverts the container image, allowing the cluster to restart gracefully on the original version. ([#10104](cloudnative-pg/cloudnative-pg#10104), [#10298](cloudnative-pg/cloudnative-pg#10298)) <!-- 1.28 1.27 --> - Improved the operator's observability by emitting native Kubernetes events during key phases of the reconciliation loop, providing visibility into the operator's decision-making process and the lifecycle of managed resources directly through `kubectl get events`. ([#10040](cloudnative-pg/cloudnative-pg#10040)) - Extended support for the `cnpg.io/reconciliationDisabled` annotation on Backup resources. This allows administrators to temporarily freeze the operator's reconciliation logic for specific backup objects. Contributed by [@GabriFedi97](https://github.com/GabriFedi97). ([#10020](cloudnative-pg/cloudnative-pg#10020)) - Added a `bin_path` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows extensions to specify directory paths for external binaries, which are automatically appended to the `PATH` environment variable of the Postgres process. ([#10250](cloudnative-pg/cloudnative-pg#10250)) - Added an `env` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows cluster administrators to define custom environment variables for the Postgres process. This field supports the `${image_root}` placeholder to dynamically resolve to the extension's absolute mount path. ([#10375](cloudnative-pg/cloudnative-pg#10375)) - Implemented a finalizer for plugins to ensure that resources managed by a plugin are gracefully cleaned up when the corresponding service is deleted. ([#9560](cloudnative-pg/cloudnative-pg#9560)) - Improved role management by verifying the instance is the primary before each reconciliation cycle, avoiding unnecessary reconciliation attempts and spurious error messages on read-only replicas. ([#9971](cloudnative-pg/cloudnative-pg#9971)) <!-- 1.28 1.27 1.25 --> - The operator now honors the `primaryUpdateMethod` when adding new PVCs to a cluster, ensuring that the rollout strategy (e.g., switchover vs. restart) is respected during storage expansion or additions. ([#9720](cloudnative-pg/cloudnative-pg#9720)) <!-- 1.28 1.27 --> - Refined the `alpha.cnpg.io/unrecoverable` annotation logic to allow it to function even on pods that have not yet reached the `Ready` state, facilitating the recovery of stuck instances. ([#9968](cloudnative-pg/cloudnative-pg#9968)) <!-- 1.28 --> - Introduced a "Terminal Error" phase for backups that encounter unrecoverable issues (such as invalid credentials or non-existent cloud buckets). This ensures the operator stops retrying doomed operations, preventing resource exhaustion and providing immediate, clear feedback in the status. ([#9353](cloudnative-pg/cloudnative-pg#9353)) - Improved monitoring of long-running backups by introducing `reconciliationStartedAt` and `reconciliationTerminatedAt` fields to the `Backup` status. This change separates the operator's internal lifecycle from the actual backup tool's execution timing (`startedAt`/`stoppedAt`), allowing users to track when the operator begins processing a request. ([#9351](cloudnative-pg/cloudnative-pg#9351)) - Added a `Pending` phase to the `Backup` status to explicitly indicate when a backup is queued and waiting for an available worker or instance availability. ([#9364](cloudnative-pg/cloudnative-pg#9364)) ##### Security and Supply Chain - **Security best practices integration**: integrated the OpenSSF baseline scanner and added a `SECURITY-INSIGHTS.yaml` file to the repository to align with industry-standard security reporting. ([#10054](cloudnative-pg/cloudnative-pg#10054), <!-- 1.28 1.27 1.25 --> [#10062](cloudnative-pg/cloudnative-pg#10062)) <!-- 1.28 1.27 1.25 --> - **SLSA provenance and SBOMs**: added SLSA (Supply-chain Levels for Software Artifacts) provenance to release binaries and container images. Additionally, enabled Software Bill of Materials (SBOM) generation within the GoReleaser pipeline for improved dependency transparency. ([#10048](cloudnative-pg/cloudnative-pg#10048), <!-- 1.28 1.27 1.25 --> [#10074](cloudnative-pg/cloudnative-pg#10074)) <!-- 1.28 1.27 1.25 --> - **Password leak prevention**: fixed a potential security risk where PostgreSQL could leak role passwords in the logs during specific reconciliation phases. ([#9950](cloudnative-pg/cloudnative-pg#9950)) <!-- 1.28 1.27 1.25 --> ##### Changes - Updated the default PostgreSQL version to 18.3 (image `18.3-system-trixie`). ([#10090](cloudnative-pg/cloudnative-pg#10090)) <!-- 1.28 1.27 1.25 --> ##### Fixes - Fixed a deadlock during operator upgrades affecting clusters using synchronous replication, where pods running the old and new operator versions computed different PostgreSQL configuration hashes, causing the uniformity check to block indefinitely and preventing both rolling updates and in-place upgrades from proceeding. ([#10342](cloudnative-pg/cloudnative-pg#10342)) <!-- 1.28 --> - Fixed an issue where fencing annotations could not be processed when the WAL disk was full, because the disk space check blocked the instance manager from starting. The check is now performed later in the lifecycle loop, after fencing is evaluated. ([#10302](cloudnative-pg/cloudnative-pg#10302)) <!-- 1.28 1.27 --> - Fixed an issue where replicas would get stuck in a `Pending` state if the `VolumeSnapshot` used for the initial bootstrap had been deleted. The operator now validates snapshot existence before use; if a snapshot is missing, it attempts to use the next available candidate or falls back to `pg_basebackup`. ([#10192](cloudnative-pg/cloudnative-pg#10192)) <!-- 1.28 1.27 1.25 --> - Prevented the "supervised primary" rollout strategy from consuming all available rollout slots, which previously caused delays in scheduled updates. Contributed by [@ermakov-oleg](https://github.com/ermakov-oleg). ([#9977](cloudnative-pg/cloudnative-pg#9977)) <!-- 1.28 1.27 1.25 --> - Fixed an issue where certain hot-standby parameter changes were not being correctly applied to replica clusters. ([#9952](cloudnative-pg/cloudnative-pg#9952)) <!-- 1.28 1.27 1.25 --> - Fixed a bug in the CNPG-I reconciler hook that could lead to skipping subsequent plugins when a "continue" result was returned. Contributed by [@sharifmshaker](https://github.com/sharifmshaker). ([#9978](cloudnative-pg/cloudnative-pg#9978)) <!-- 1.28 1.27 --> - Fixed a deadlock scenario that occurred when attempting to resize a filesystem on a PVC that was not currently attached to a Pod. Contributed by [@jmealo](https://github.com/jmealo). ([#9981](cloudnative-pg/cloudnative-pg#9981)) <!-- 1.28 1.27 --> - Fixed webhook validation of bootstrap recovery sources to accept external clusters configured with `ConnectionParameters` (for `pg_basebackup`-based recovery). Previously, these were incorrectly rejected unless a Barman object store or CNPG-i plugin was also configured. ([#10268](cloudnative-pg/cloudnative-pg#10268)) <!-- 1.28 1.27 1.25 --> - Volume names for extensions and tablespaces are now prefixed to avoid naming collisions with standard cluster volumes. ([#9973](cloudnative-pg/cloudnative-pg#9973)) <!-- 1.28 1.27 --> - When hibernating a non-healthy cluster, the operator now reports a `WaitingForHealthy` condition, making the deferred hibernation state visible through `cnpg status`. ([#10193](cloudnative-pg/cloudnative-pg#10193)) <!-- 1.28 1.27 1.25 --> - Fixed fencing to work correctly even when the target pod does not exist. Fencing operates on a cluster-level annotation and should not depend on pod existence; instance name validation is now performed only in the `cnpg fencing on` command. ([#10035](cloudnative-pg/cloudnative-pg#10035)) <!-- 1.28 1.27 1.25 --> - Fixed the cluster and pooler service reconcilers to correctly handle changes to all spec fields when using the patch update strategy. The reconciler now uses RFC 7386 JSON Merge Patching, preventing cloud-provider-set fields (such as `loadBalancerClass`) from being inadvertently removed. ([#10190](cloudnative-pg/cloudnative-pg#10190), [#10311](cloudnative-pg/cloudnative-pg#10311)) <!-- 1.28 1.27 1.25 --> - Fixed a race condition in the deprecated in-tree Barman Cloud backup implementation affecting parallel WAL restore, where prefetched files could be read while still being downloaded, causing PostgreSQL recovery to fail with "invalid checkpoint record" errors. ([#10285](cloudnative-pg/cloudnative-pg#10285)) <!-- 1.28 1.27 1.25 --> - Fixed the timeline history file validation to also apply to plugin-based WAL restore. Previously, the protection introduced in [#9650](cloudnative-pg/cloudnative-pg#9650) only covered in-tree restores, allowing plugins to bypass the check and download future timeline history files, causing timeline mismatch errors on replicas. ([#9849](cloudnative-pg/cloudnative-pg#9849)) <!-- 1.28 1.27 1.25 --> - `cnpg` plugin: - The cnpg plugin now correctly propagates ImagePullSecrets to the `pgbench` Job pod template. ([#10174](cloudnative-pg/cloudnative-pg#10174)) <!-- 1.28 1.27 1.25 --> ##### Supported versions - Kubernetes 1.35, 1.34, and 1.33 - PostgreSQL 18, 17, 16, 15, and 14 - PostgreSQL 18.3 is the default image - [PostgreSQL 14 support ends on November 12, 2026](https://www.postgresql.org/support/versioning/)
##### [\`v1.29.0\`](https://github.com/cloudnative-pg/cloudnative-pg/releases/tag/v1.29.0) **Release date:** Mar 31, 2026 ##### Important changes - Updated the deprecation notice for native (in-tree) Barman Cloud support to reflect that it will now be removed in CloudNativePG 1.30.0, rather than 1.29.0. Users are still encouraged to migrate to the Barman Cloud Plugin. ([#10167](cloudnative-pg/cloudnative-pg#10167)) <!-- 1.28 1.27 --> ##### Features - **PostgreSQL extensions in image catalogs**: extended the `ImageCatalog` functionality to support PostgreSQL extensions. This allows users to define and manage extension-specific images within a catalog, simplifying the deployment of customized PostgreSQL builds. ([#9781](cloudnative-pg/cloudnative-pg#9781)) - **Dynamic network access control via pod selectors**: introduced the declarative definition of `podSelectorRefs` to manage `pg_hba.conf` rules dynamically. By using label selectors to identify client pods, the operator automatically resolves their ephemeral IP addresses and updates the PostgreSQL host-based authentication rules accordingly. This ensures that only authorized workloads in the same namespace can connect to the database, eliminating the need for manual IP management or static CIDR ranges. ([#10148](cloudnative-pg/cloudnative-pg#10148)) - **Shared `ServiceAccount` support**: added an optional `serviceAccountName` field to both `Cluster` and `Pooler` specifications. This allows multiple resources to share a pre-existing ServiceAccount, facilitating one-time IAM configurations (such as AWS IRSA, GCP Workload Identity, or Azure Workload Identity) across all clusters and poolers. Contributed by [@bozkayasalihx](https://github.com/bozkayasalihx). ([#9287](cloudnative-pg/cloudnative-pg#9287)) ##### Enhancements - Improved the `Pooler` CRD with support for granular configuration of TLS cipher suites and minimum/maximum TLS versions. This enables administrators to meet strict security compliance requirements for pooler-to-client and pooler-to-server connections. Contributed by [@alex1989hu](https://github.com/alex1989hu). ([#9571](cloudnative-pg/cloudnative-pg#9571)) <!-- 1.28 1.27 1.25 --> - Improved the reliability of major upgrades by setting `BackoffLimit=0` on the upgrade job, preventing unnecessary retries of a failed `pg_upgrade`. The operator now automatically deletes the failed job when a user reverts the container image, allowing the cluster to restart gracefully on the original version. ([#10104](cloudnative-pg/cloudnative-pg#10104), [#10298](cloudnative-pg/cloudnative-pg#10298)) <!-- 1.28 1.27 --> - Improved the operator's observability by emitting native Kubernetes events during key phases of the reconciliation loop, providing visibility into the operator's decision-making process and the lifecycle of managed resources directly through `kubectl get events`. ([#10040](cloudnative-pg/cloudnative-pg#10040)) - Extended support for the `cnpg.io/reconciliationDisabled` annotation on Backup resources. This allows administrators to temporarily freeze the operator's reconciliation logic for specific backup objects. Contributed by [@GabriFedi97](https://github.com/GabriFedi97). ([#10020](cloudnative-pg/cloudnative-pg#10020)) - Added a `bin_path` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows extensions to specify directory paths for external binaries, which are automatically appended to the `PATH` environment variable of the Postgres process. ([#10250](cloudnative-pg/cloudnative-pg#10250)) - Added an `env` field to the `postgresql.extensions` stanza, as well as in `ImageCatalog` and `ClusterImageCatalog` resources. This allows cluster administrators to define custom environment variables for the Postgres process. This field supports the `${image_root}` placeholder to dynamically resolve to the extension's absolute mount path. ([#10375](cloudnative-pg/cloudnative-pg#10375)) - Implemented a finalizer for plugins to ensure that resources managed by a plugin are gracefully cleaned up when the corresponding service is deleted. ([#9560](cloudnative-pg/cloudnative-pg#9560)) - Improved role management by verifying the instance is the primary before each reconciliation cycle, avoiding unnecessary reconciliation attempts and spurious error messages on read-only replicas. ([#9971](cloudnative-pg/cloudnative-pg#9971)) <!-- 1.28 1.27 1.25 --> - The operator now honors the `primaryUpdateMethod` when adding new PVCs to a cluster, ensuring that the rollout strategy (e.g., switchover vs. restart) is respected during storage expansion or additions. ([#9720](cloudnative-pg/cloudnative-pg#9720)) <!-- 1.28 1.27 --> - Refined the `alpha.cnpg.io/unrecoverable` annotation logic to allow it to function even on pods that have not yet reached the `Ready` state, facilitating the recovery of stuck instances. ([#9968](cloudnative-pg/cloudnative-pg#9968)) <!-- 1.28 --> - Introduced a "Terminal Error" phase for backups that encounter unrecoverable issues (such as invalid credentials or non-existent cloud buckets). This ensures the operator stops retrying doomed operations, preventing resource exhaustion and providing immediate, clear feedback in the status. ([#9353](cloudnative-pg/cloudnative-pg#9353)) - Improved monitoring of long-running backups by introducing `reconciliationStartedAt` and `reconciliationTerminatedAt` fields to the `Backup` status. This change separates the operator's internal lifecycle from the actual backup tool's execution timing (`startedAt`/`stoppedAt`), allowing users to track when the operator begins processing a request. ([#9351](cloudnative-pg/cloudnative-pg#9351)) - Added a `Pending` phase to the `Backup` status to explicitly indicate when a backup is queued and waiting for an available worker or instance availability. ([#9364](cloudnative-pg/cloudnative-pg#9364)) ##### Security and Supply Chain - **Security best practices integration**: integrated the OpenSSF baseline scanner and added a `SECURITY-INSIGHTS.yaml` file to the repository to align with industry-standard security reporting. ([#10054](cloudnative-pg/cloudnative-pg#10054), <!-- 1.28 1.27 1.25 --> [#10062](cloudnative-pg/cloudnative-pg#10062)) <!-- 1.28 1.27 1.25 --> - **SLSA provenance and SBOMs**: added SLSA (Supply-chain Levels for Software Artifacts) provenance to release binaries and container images. Additionally, enabled Software Bill of Materials (SBOM) generation within the GoReleaser pipeline for improved dependency transparency. ([#10048](cloudnative-pg/cloudnative-pg#10048), <!-- 1.28 1.27 1.25 --> [#10074](cloudnative-pg/cloudnative-pg#10074)) <!-- 1.28 1.27 1.25 --> - **Password leak prevention**: fixed a potential security risk where PostgreSQL could leak role passwords in the logs during specific reconciliation phases. ([#9950](cloudnative-pg/cloudnative-pg#9950)) <!-- 1.28 1.27 1.25 --> ##### Changes - Updated the default PostgreSQL version to 18.3 (image `18.3-system-trixie`). ([#10090](cloudnative-pg/cloudnative-pg#10090)) <!-- 1.28 1.27 1.25 --> ##### Fixes - Fixed a deadlock during operator upgrades affecting clusters using synchronous replication, where pods running the old and new operator versions computed different PostgreSQL configuration hashes, causing the uniformity check to block indefinitely and preventing both rolling updates and in-place upgrades from proceeding. ([#10342](cloudnative-pg/cloudnative-pg#10342)) <!-- 1.28 --> - Fixed an issue where fencing annotations could not be processed when the WAL disk was full, because the disk space check blocked the instance manager from starting. The check is now performed later in the lifecycle loop, after fencing is evaluated. ([#10302](cloudnative-pg/cloudnative-pg#10302)) <!-- 1.28 1.27 --> - Fixed an issue where replicas would get stuck in a `Pending` state if the `VolumeSnapshot` used for the initial bootstrap had been deleted. The operator now validates snapshot existence before use; if a snapshot is missing, it attempts to use the next available candidate or falls back to `pg_basebackup`. ([#10192](cloudnative-pg/cloudnative-pg#10192)) <!-- 1.28 1.27 1.25 --> - Prevented the "supervised primary" rollout strategy from consuming all available rollout slots, which previously caused delays in scheduled updates. Contributed by [@ermakov-oleg](https://github.com/ermakov-oleg). ([#9977](cloudnative-pg/cloudnative-pg#9977)) <!-- 1.28 1.27 1.25 --> - Fixed an issue where certain hot-standby parameter changes were not being correctly applied to replica clusters. ([#9952](cloudnative-pg/cloudnative-pg#9952)) <!-- 1.28 1.27 1.25 --> - Fixed a bug in the CNPG-I reconciler hook that could lead to skipping subsequent plugins when a "continue" result was returned. Contributed by [@sharifmshaker](https://github.com/sharifmshaker). ([#9978](cloudnative-pg/cloudnative-pg#9978)) <!-- 1.28 1.27 --> - Fixed a deadlock scenario that occurred when attempting to resize a filesystem on a PVC that was not currently attached to a Pod. Contributed by [@jmealo](https://github.com/jmealo). ([#9981](cloudnative-pg/cloudnative-pg#9981)) <!-- 1.28 1.27 --> - Fixed webhook validation of bootstrap recovery sources to accept external clusters configured with `ConnectionParameters` (for `pg_basebackup`-based recovery). Previously, these were incorrectly rejected unless a Barman object store or CNPG-i plugin was also configured. ([#10268](cloudnative-pg/cloudnative-pg#10268)) <!-- 1.28 1.27 1.25 --> - Volume names for extensions and tablespaces are now prefixed to avoid naming collisions with standard cluster volumes. ([#9973](cloudnative-pg/cloudnative-pg#9973)) <!-- 1.28 1.27 --> - When hibernating a non-healthy cluster, the operator now reports a `WaitingForHealthy` condition, making the deferred hibernation state visible through `cnpg status`. ([#10193](cloudnative-pg/cloudnative-pg#10193)) <!-- 1.28 1.27 1.25 --> - Fixed fencing to work correctly even when the target pod does not exist. Fencing operates on a cluster-level annotation and should not depend on pod existence; instance name validation is now performed only in the `cnpg fencing on` command. ([#10035](cloudnative-pg/cloudnative-pg#10035)) <!-- 1.28 1.27 1.25 --> - Fixed the cluster and pooler service reconcilers to correctly handle changes to all spec fields when using the patch update strategy. The reconciler now uses RFC 7386 JSON Merge Patching, preventing cloud-provider-set fields (such as `loadBalancerClass`) from being inadvertently removed. ([#10190](cloudnative-pg/cloudnative-pg#10190), [#10311](cloudnative-pg/cloudnative-pg#10311)) <!-- 1.28 1.27 1.25 --> - Fixed a race condition in the deprecated in-tree Barman Cloud backup implementation affecting parallel WAL restore, where prefetched files could be read while still being downloaded, causing PostgreSQL recovery to fail with "invalid checkpoint record" errors. ([#10285](cloudnative-pg/cloudnative-pg#10285)) <!-- 1.28 1.27 1.25 --> - Fixed the timeline history file validation to also apply to plugin-based WAL restore. Previously, the protection introduced in [#9650](cloudnative-pg/cloudnative-pg#9650) only covered in-tree restores, allowing plugins to bypass the check and download future timeline history files, causing timeline mismatch errors on replicas. ([#9849](cloudnative-pg/cloudnative-pg#9849)) <!-- 1.28 1.27 1.25 --> - `cnpg` plugin: - The cnpg plugin now correctly propagates ImagePullSecrets to the `pgbench` Job pod template. ([#10174](cloudnative-pg/cloudnative-pg#10174)) <!-- 1.28 1.27 1.25 --> ##### Supported versions - Kubernetes 1.35, 1.34, and 1.33 - PostgreSQL 18, 17, 16, 15, and 14 - PostgreSQL 18.3 is the default image - [PostgreSQL 14 support ends on November 12, 2026](https://www.postgresql.org/support/versioning/)
Introduces a declarative way to manage
pg_hbarules by resolving pod label selectors into IP addresses, eliminating the need for static CIDR ranges or manual updates when client pods restart.Users define named label selectors in
.spec.podSelectorRefsand reference them with${podselector:NAME}inpg_hbaaddress fields. The operator resolves matching pod IPs and the instance manager expands each reference into individual/32or/128entries at render time, with automatic reload on pod lifecycle changes.Closes #10087