Skip to content

Instantly share code, notes, and snippets.

@nmeylan
Created July 10, 2019 12:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nmeylan/15776051690d53acccbf7a84722ce3b7 to your computer and use it in GitHub Desktop.
Save nmeylan/15776051690d53acccbf7a84722ce3b7 to your computer and use it in GitHub Desktop.
tail kubernetes logs
#!/bin/sh
kubectl get pods -n NAMESPACE | grep -o -e .*${1}[\-a-z0-9]* | while read line; do kubectl logs -f $line -n NAMESPACE -c ${1} --tail 100; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment