ci: get logs from all pods, not only the 1st

The JSON formatting will return the name of the first pod, not all pods
on the list. By useing `items[*]` the names of all pods will be
returned. This causes all logs to be fetched, instead of only the logs
from the 1st pod.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
This commit is contained in:
Niels de Vos 2021-05-17 17:17:54 +02:00 committed by mergify[bot]
parent ad2c02bdc0
commit 0dd488374f

View File

@ -45,7 +45,7 @@ log minikube_ssh sudo tar c /var/lib/rook | tar xvO
# gets status of the Rook deployment
log kubectl -n rook-ceph get events
log kubectl -n rook-ceph get pods
for POD in $(kubectl -n rook-ceph get pods -o jsonpath='{.items[0].metadata.name}')
for POD in $(kubectl -n rook-ceph get pods -o jsonpath='{.items[*].metadata.name}')
do
log kubectl -n rook-ceph describe pod "${POD}"
log kubectl -n rook-ceph logs "${POD}" --all-containers