Skip to content

Instantly share code, notes, and snippets.

@jcantrill
Created September 5, 2018 18:17
Show Gist options
  • Save jcantrill/a0d7a612a5cab8eae9adba3d32bc6776 to your computer and use it in GitHub Desktop.
Save jcantrill/a0d7a612a5cab8eae9adba3d32bc6776 to your computer and use it in GitHub Desktop.
get the images
#!/bin/bash
pod=$1
echo "DCs"
echo "----"
oc get dc -n logging -o yaml | grep image: | sort | uniq
echo "DSs"
echo "----"
oc get ds -n logging -o yaml | grep image: | sort | uniq
echo "Pods"
echo "----"
for p in $(oc get pods -n logging -o jsonpath={.items[*].metadata.name}); do
echo "$p : $(oc get pod $p -n logging -o yaml | grep image: | sort | uniq)"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment