Skip to content

Instantly share code, notes, and snippets.

@mmguero
Created May 5, 2026 20:28
Show Gist options
  • Select an option

  • Save mmguero/bd3760e9ba1e24ebdc27c1807be2ea02 to your computer and use it in GitHub Desktop.

Select an option

Save mmguero/bd3760e9ba1e24ebdc27c1807be2ea02 to your computer and use it in GitHub Desktop.
get the sha256 sums of some docker images matching a pattern
for IMG in $(docker images --format json | jq -r '"\(.Repository):\(.Tag)"' | grep -P "idaholab/malcolm.+:26\.05\.0"); do img='IMAGE:TAG'; docker inspect --format='{{range .RepoDigests}}{{println .}}{{end}}' "$IMG" | awk -v repo="${IMG%:*}" '$0 ~ "^"repo"@sha256:" {print; exit}'; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment