Docker

Space Usage [001]

docker system df

Save docker image [002]

# pull the image
docker pull ubuntu

# save the image to a file
docker save -o ubuntu_image.docker ubuntu

# load the image from file
docker load ubuntu_image.docker

Change VHD location [003]

Docker | Settings | Advanced | Change VHD Location

Note: The selected directory should be empty. Docker will move the image

Start bash from running container [004]

docker exec [OPTIONS] CONTAINER COMMAND [ARG…] [flags]

e.g., docker exec -it oracle /bin/bash

-i - Interactive -t - Pusedo TTY oracle - Container name /bin/bash - Command to be executed

Commit

Usage: docker commit [OPTIONS] CONTAINER [REPOSITORY[:TAG]]

Create a new image from a container’s changes

Options:
-a, --author string
 Author (e.g., “John Hannibal Smith <hannibal@a-team.com>”)
-c, --change list
 Apply Dockerfile instruction to the created image
-m, --message string
 Commit message
-p, --pause Pause container during commit (default true)