Last active
April 18, 2019 12:35
-
-
Save rmetzler/aaa9b0d42c033064cf44029d9636f537 to your computer and use it in GitHub Desktop.
kubectl top node,pod
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
join -a 1 -1 1 -2 2 \ | |
<(kubectl top node | sed -e 's/NAME/NODE/') \ | |
<( \ | |
join -1 1 -2 1 \ | |
-o 1.1,2.7,1.2,1.3 \ | |
<(kubectl top pod) \ | |
<(kubectl get pod -o wide) \ | |
| sed -e 's/NAME/POD/' \ | |
) | column -t -s' ' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
it doesn't have namespaces yet (
kubectl top pod --all-namespaces
)