building
- use Docker build instead of docker-compose build (or up –build) to take advantage of layer cashing (not so sure)
Restart
Debug
see this article
docker exec
“ ” docker exec
-it bash docker logs
docker ps -a : list all containers
docker rm (-f)
: remove a container docker inspect
docker network ls
Connecting to the database
- Use the container name and not localhost in the container
Editing docker files / library files
Usually no editor is present in the container
See this
Install vim
- Connect as root :
docker exec -u 0 -it mycontainer bash
- Connect as root :
install vim
Use
docker cp