-
Notifications
You must be signed in to change notification settings - Fork 9
Description
There is alot of obsolete / deprecated resources that could be cleaned up to make the sensitive-data-archive repo more clean.
For example the "v0.y.z", and "v2.y.z" versions of the sensitive-data-archive are obsolete / deprecated and their
images, tags, releases, etc can be cleaned up. Also any helm charts that utilise these should be deleted.
Additional context
We have around ~600 "sda" tags that could be cleaned up from "v0" and "v2", and around 3400 ghcr images
And some chart tags / release (essentially any chart version that have appVersion at "v0.y.z" or "v2.y.z")
v2.y.z have 11 tags referenced by the charts
v0.y.z have 112 tags referenced
More context: https://nbisweden.slack.com/archives/G01NHJJA9R9/p1772607925784989?thread_ts=1772205004.304129&cid=G01NHJJA9R9
git tag -l "v0*" | wc -l
542
git tag -l "v2*" | wc -l
66
gh api -H "Accept: application/vnd.github+json" /orgs/neicnordic/packages/container/sensitive-data-archive/versions --paginate > all_containers
cat all_containers | jq -r --argjson now "$(date +%s)" --arg sem_ver '^v?[02]+\.[0-9]+\.[0-9]+([.-][0-9A-Za-z.-]+)?$' '
.[] |
select(.metadata.container.tags != null) |
select(
[ .metadata.container.tags[] | test($sem_ver) ] | any
) |
"\(.id) \(.metadata.container.tags | join(","))"
' > filtered_containers_sem_ver_v0_and_v2
cat filtered_containers_sem_ver_v0_and_v2 | wc -l
3400