Skip to content

Instantly share code, notes, and snippets.

@veve90
Last active September 13, 2018 13:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save veve90/3e8a410a5597346f02e35d368dc84ae8 to your computer and use it in GitHub Desktop.
Save veve90/3e8a410a5597346f02e35d368dc84ae8 to your computer and use it in GitHub Desktop.
#start docker daemon (on viperr)
systemctl restart docker
#start bash in docker
docker exec -ti container_name bash
#docker informations
docker -D info
# start docker container
docker run -p 8080:8080 hello-world
#list containeurs
docker ps -a
# list images
docker images -a
#remove image
docker rmi Image Image
# liste de tous les containeurs et leur IP
docker inspect -f '{{.Name}} - {{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -aq)
#remove all containers
docker rm $(docker ps -a -q)
# no proxy while run ==> edit the execStart
# use option --userland-proxy=false
#docker-compose installation directory: /usr/local/bin and copied to /usr/bin
#docker-compose is starting with the comand docker-compose up in the folder where we have the yml file
#overlay2
docker volume prune -f
docker system prune -a -f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment