Last active
November 6, 2023 19:31
-
-
Save joepvd/f2feacd28ecda8bd46eeedc86d31fd42 to your computer and use it in GitHub Desktop.
review-plashet-logs
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
#!/usr/bin/env bash | |
versions=( | |
"4.6" | |
"4.7" | |
"4.8" | |
"4.9" | |
"4.10" | |
"4.11" | |
"4.12" | |
"4.13" | |
"4.14" | |
"4.15" | |
) | |
get_urls() { | |
version="$1" | |
doozer --group "openshift-$version" --assembly stream config:read-group repos --yaml 2> /dev/null | | |
yq -r ' | |
. | to_entries[] | |
| .value.conf.baseurl.x86_64 | |
| select(. | contains("/plashets/")) | |
| sub("x86_64/os$"; "plashet.log") | |
' | |
} | |
for version in "${versions[@]}"; do | |
for url in $(get_urls "$version"); do | |
curl -s "$url" | | |
awk -v "url=$url" ' | |
/ERROR/ { | |
e = gensub(/.*Skipping tagged /, "", "g") | |
e = gensub(/because it is older than a released version:/, "is_older_than", "g", e) | |
print url, e | |
}' | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment