Skip to content

Instantly share code, notes, and snippets.

@matschundbrei
Last active June 27, 2021 22:50
Show Gist options
  • Save matschundbrei/e351b827796d413200a9f81c33f8f549 to your computer and use it in GitHub Desktop.
Save matschundbrei/e351b827796d413200a9f81c33f8f549 to your computer and use it in GitHub Desktop.
Update all locally pulled and tagged docker images
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'
docker image ls | \
tail -n +2 | \
grep -v '<none>' | \
awk '{print $1 ":" $2 }' | \
xargs -n1 docker pull
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment