Closed fireba11 closed 1 year ago
I managed to narrow it down to scriptpath with -n works, the one without is broken.
Using $NAME without ever defining it was a bad idea. It's an ENV on WSL m( Will make a pull request with a fix after looking at the jq errors for pvc mode.
I got several strange issues ...
./check_kubernetes.sh -m statefulsets -N namespace -n sts-name OK. Statefulset namespace/sts-name 3/3 ready
works fine while
./check_kubernetes.sh -m statefulsets -N namespace -n sts-name No statefulsets found
doesn't find anything. Same with most other checks, nodes and unboundpvc work while pvc doesn't and even gives jq errors:
jq: error (at:1): Cannot iterate over null (null)
jq: error (at :1): Cannot iterate over null (null)
jq: error (at :1): Cannot iterate over null (null)
OK. No problem on 0 pvc storage
Also tried using -H and -T to not use kubectl, but didn't change anything.
Any ideas?