Skip to content

Commit 46f24cb

Browse files
committed
keycloak: use correct keycloak health endpoints
1 parent 353f092 commit 46f24cb

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

ci-operator/step-registry/idp/external-oidc/keycloak/server/idp-external-oidc-keycloak-server-commands.sh

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,48 @@ spec:
4444
"
4545
fi
4646

47+
# Fix health probes to use proper Keycloak health endpoints instead of "/" which redirects
48+
# This prevents pathological probe failures that trigger test invariant violations
49+
oc patch dc/keycloak -n keycloak --type=json -p='[
50+
{
51+
"op": "replace",
52+
"path": "/spec/template/spec/containers/0/readinessProbe",
53+
"value": {
54+
"httpGet": {
55+
"path": "/health/ready",
56+
"port": 8080,
57+
"scheme": "HTTP"
58+
},
59+
"initialDelaySeconds": 10
60+
}
61+
},
62+
{
63+
"op": "replace",
64+
"path": "/spec/template/spec/containers/0/livenessProbe",
65+
"value": {
66+
"httpGet": {
67+
"path": "/health/live",
68+
"port": 8080,
69+
"scheme": "HTTP"
70+
},
71+
"initialDelaySeconds": 10
72+
}
73+
},
74+
{
75+
"op": "add",
76+
"path": "/spec/template/spec/containers/0/startupProbe",
77+
"value": {
78+
"httpGet": {
79+
"path": "/health/started",
80+
"port": 8080,
81+
"scheme": "HTTP"
82+
},
83+
"failureThreshold": 20,
84+
"periodSeconds": 10
85+
}
86+
}
87+
]'
88+
4789
prepare_keycloak_client_files
4890
prepare_keycloak_user_data
4991
prepare_keycloak_setup_script

0 commit comments

Comments
 (0)