Skip to content

Instantly share code, notes, and snippets.

@HUGHNew
Created February 28, 2022 04:34
Show Gist options
  • Save HUGHNew/277d6e624af60efd50446e526a601e64 to your computer and use it in GitHub Desktop.
Save HUGHNew/277d6e624af60efd50446e526a601e64 to your computer and use it in GitHub Desktop.
some bash code snippet for docker operation(updating)
alias Docker="sudo docker"
# rm <none> images which is generated by error when building
Docker rmi $(Docker images|grep none|awk '{print $3}'|xargs)
# remove all containers
Docker rm $(Docker ps -aq|xargs)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment