Skip to content

Commit 1255dd0

Browse files
committed
docs: Update getting-started.adoc
1 parent a66761e commit 1255dd0

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

modules/ROOT/pages/getting-started.adoc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -235,14 +235,11 @@ If all has gone well then you will have successfully deployed a Stackable cluste
235235

236236
=== Apache ZooKeeper
237237

238-
We can test ZooKeeper by running the ZooKeeper CLI shell. The easiest way to do this is to run the CLI shell on the pod that is running ZooKeeper. It might be necessary to determine and set the port.
238+
We can test ZooKeeper by running the ZooKeeper CLI shell. The easiest way to do this is to run the CLI shell on the pod that is running ZooKeeper.
239239

240240
[source,bash]
241241
----
242-
kubectl exec -i -t simple-zk-server-primary-0 -- bin/zkCli.sh
243-
# optional, determine the port
244-
PORT=$(kubectl get pod simple-zk-server-primary-0 -o=jsonpath='{.spec.containers[0].ports[0].containerPort}')
245-
echo $PORT
242+
PORT="$(kubectl get pod simple-zk-server-primary-0 -o=json | jq '.spec.containers[].ports[] | select(.name == "zk") | .containerPort')"
246243
kubectl exec -i -t simple-zk-server-primary-0 -- bin/zkCli.sh -server "localhost:$PORT"
247244
----
248245

0 commit comments

Comments
 (0)