Skip to content

Commit 109ea87

Browse files
committed
feat(instance): liveness probe isolation checker (#7466)%0A%0AEnhances the liveness probe logic for primary instances in HA clusters%0Ato detect network isolation scenarios.%0A%0AThe probe first checks if the Pod can reach the API server. If the API%0Aserver is unreachable, it then attempts to contact peer PostgreSQL%0Ainstances in the same cluster via a REST entrypoint.%0A%0AIf neither the API server nor any replicas are reachable, the liveness%0Aprobe fails, prompting Kubernetes to restart the Pod.%0A%0AUpon restart, the instance manager will refuse to start PostgreSQL, as%0Ait cannot download the Cluster definition—preventing unsafe behavior in%0Aisolated environments.%0A%0AThis behavior applies only to primary instances in clusters with HA%0Areplicas and is disabled by default.%0A%0ACloses: #7465%0A%0ASigned-off-by: Leonardo Cecchi <[email protected]>%0ASigned-off-by: Armando Ruocco <[email protected]>%0ASigned-off-by: Niccolò Fei <[email protected]>%0ASigned-off-by: Gabriele Bartolini <[email protected]>%0ASigned-off-by: Marco Nenciarini <[email protected]>%0ACo-authored-by: Armando Ruocco <[email protected]>%0ACo-authored-by: Niccolò Fei <[email protected]>%0ACo-authored-by: Gabriele Bartolini <[email protected]>%0ACo-authored-by: Marco Nenciarini <[email protected]>
cloudnative-pg/cloudnative-pg@refs/heads/main
1 parent 60ebf43 commit 109ea87

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

manifests/operator-manifest.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6654,6 +6654,9 @@ spec:
66546654
description: InstanceReportedState describes the last reported state
66556655
of an instance during a reconciliation loop
66566656
properties:
6657+
ip:
6658+
description: IP address of the instance
6659+
type: string
66576660
isPrimary:
66586661
description: indicates if an instance is the primary one
66596662
type: boolean
@@ -17766,7 +17769,7 @@ spec:
1776617769
- name: PULL_SECRET_NAME
1776717770
value: cnpg-pull-secret
1776817771
- name: OPERATOR_IMAGE_NAME
17769-
value: ghcr.io/cloudnative-pg/cloudnative-pg-testing:main@sha256:492bb3dc7716b1e6daf7eb9cc91d25d5de967dc6ce0c69c06f31d45026585a49
17772+
value: ghcr.io/cloudnative-pg/cloudnative-pg-testing:main@sha256:1bcff4462d8a3ab108a216c0b3316bce525edcfdc1ff0809d1e6b1c201b7a7c8
1777017773
- name: OPERATOR_NAMESPACE
1777117774
valueFrom:
1777217775
fieldRef:
@@ -17776,7 +17779,7 @@ spec:
1777617779
envFrom:
1777717780
- configMapRef:
1777817781
name: cnpg-controller-manager-env-g67c9ghf8g
17779-
image: ghcr.io/cloudnative-pg/cloudnative-pg-testing:main@sha256:492bb3dc7716b1e6daf7eb9cc91d25d5de967dc6ce0c69c06f31d45026585a49
17782+
image: ghcr.io/cloudnative-pg/cloudnative-pg-testing:main@sha256:1bcff4462d8a3ab108a216c0b3316bce525edcfdc1ff0809d1e6b1c201b7a7c8
1778017783
imagePullPolicy: Always
1778117784
livenessProbe:
1778217785
httpGet:

0 commit comments

Comments
 (0)