Created at:

Modified at:

docker notes

Generic notes

Running a command inside a running container

# docker exec -it <container_name> bash

Checking a docker image content


The easiest approach is to just start a shell container:

# docker run -it imagename bash

How to see docker image contents

Changing docker IP prefix

By default docker uses subnet. To change it to somewhere else, create the file /etc/docker/daemon.json with a content similar to the following one:

    "bip": ""

How to Get a Docker Container IP Address

Deleting a named docker volume


1. Stop containers with docker stop or docker-container stop or other command.

2. Remove containers that use the volume with docker rm.

3. List volumes with docker volume ls.

4. Remove volumes with docker volume rm.

5. Recreate and start containers with docker-container up -d or other command.