Skip to content

Instantly share code, notes, and snippets.

@ColinLeverger
Created December 8, 2016 11:36
Show Gist options
  • Save ColinLeverger/b87957eb2e2256646718f13d156e6982 to your computer and use it in GitHub Desktop.
Save ColinLeverger/b87957eb2e2256646718f13d156e6982 to your computer and use it in GitHub Desktop.
Update all Docker images
docker images | grep -v REPOSITORY | awk '{print $1}' | xargs -L1 docker pull
@giggio
Copy link

giggio commented Apr 30, 2019

I have been using this one:

docker images --format "{{.Repository}}:{{.Tag}}" | grep --invert-match '<none>' | xargs -L1 docker pull

It removes the untagged images and pulls all by tag.

@michaellwest
Copy link

For PowerShell users this could be helpful:

docker images --format "{{.Repository}}:{{.Tag}}" | ForEach-Object { docker pull $_ }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment