Skip to content

Commit b70ce01

Browse files
authored
fix: JupyterHub/Keycloak demo fixes pre-26.3 (#381)
redo jq command due to distro changes
1 parent 1f8b934 commit b70ce01

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

stacks/jupyterhub-keycloak/keycloak.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,9 @@ spec:
6161
while :
6262
do
6363
echo "Determining Keycloak public reachable address"
64-
KEYCLOAK_ADDRESS=$(kubectl get svc keycloak -o json | jq -r --argfile endpoints <(kubectl get endpoints keycloak -o json) --argfile nodes <(kubectl get nodes -o json) '($nodes.items[] | select(.metadata.name == $endpoints.subsets[].addresses[].nodeName) | .status.addresses | map(select(.type == "ExternalIP" or .type == "InternalIP")) | min_by(.type) | .address | tostring) + ":" + (.spec.ports[] | select(.name == "https") | .nodePort | tostring)')
64+
ENDPOINTS=$(kubectl get endpoints keycloak -o json)
65+
NODES=$(kubectl get nodes -o json)
66+
KEYCLOAK_ADDRESS=$(kubectl get svc keycloak -o json | jq -r --argjson endpoints "$ENDPOINTS" --argjson nodes "$NODES" '($nodes.items[] | select(.metadata.name == $endpoints.subsets[].addresses[].nodeName) | .status.addresses | map(select(.type == "ExternalIP" or .type == "InternalIP")) | min_by(.type) | .address | tostring) + ":" + (.spec.ports[] | select(.name == "https") | .nodePort | tostring)')
6567
echo "Found Keycloak running at $KEYCLOAK_ADDRESS"
6668
6769
if [ ! -z "$KEYCLOAK_ADDRESS" ]; then

0 commit comments

Comments
 (0)