Created
December 20, 2018 17:31
-
-
Save jboyd01/c167733eca96cace9a91d64ab2225961 to your computer and use it in GitHub Desktop.
script to pull all service catalog pod logs
This file contains hidden or 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 | |
for p in $(oc get pods -n kube-service-catalog -o name -l app=apiserver); do | |
pod=$(sed -e 's/pod\///g'<<<$p) | |
oc logs $pod -c apiserver -n kube-service-catalog > /tmp/artifacts/$pod.log | |
done | |
for p in $(oc get pods -n kube-service-catalog -o name -l app=controller-manager); do | |
pod=$(sed -e 's/pod\///g'<<<$p) | |
oc logs $pod -n kube-service-catalog > /tmp/artifacts/$pod.log | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment