Created
March 25, 2021 19:07
-
-
Save jovemfelix/d06f9993c10845bac5cf68f800a97a22 to your computer and use it in GitHub Desktop.
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
export CREDS=$(oc whoami):$(oc whoami -t) | |
export IMAGE_FILE_PATH=image-final | |
export OUTPUT_CVS_FOUND_PATH=image-url-found.csv | |
i=0 | |
rm -f $OUTPUT_CVS_FOUND_PATH | |
cat $IMAGE_FILE_PATH | while read line | |
do | |
((i = i + 1)) | |
registry="$line" | |
echo "$i --> $registry" | |
imageUrl=$(skopeo inspect --tls-verify=false --creds=$CREDS docker://$registry | jq '.Labels.url') | |
echo "$registry;$imageUrl" >> $OUTPUT_CVS_FOUND_PATH | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment