Skip to content

Instantly share code, notes, and snippets.

@johnkors
Created March 12, 2018 14:28
Show Gist options
  • Save johnkors/618ba76554277166d2fa440d1ec0843a to your computer and use it in GitHub Desktop.
Save johnkors/618ba76554277166d2fa440d1ec0843a to your computer and use it in GitHub Desktop.
docker-prune.ps1
docker ps -a -q -f status=exited -f status=created | foreach-object {docker rm -f $PSItem.toString() }
docker images | select-string "<none>" | ConvertFrom-String) | Select -ExpandProperty "P3"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment