|
run
|
Create and run a container from an image
|
|
run --rm
|
Automatically remove the container when it exits
|
|
run -d
|
Run container in background and print container ID
|
|
start
|
Start one or more stopped containers
|
|
CTRL+P, CTRL+Q
|
Detach from container without killing it
|
|
version (optional)
|
|
services (optional)
|
|
volumes
|
|
networks
|
|
image
|
|
ports
|
|
environment
|
|
networks
|
|
volumes
|
|
images
|
List local images
|
|
ps
|
To list currently running containers
|
|
history
|
Show the history of an image
|
|
inspect
|
Return low-level information on Docker objects
|
|
attach
|
Attach local standard input, output, and error streams to a running container
|
|
stop
|
Stop one or more running containers
|
|
logs
|
Fetch the logs of a container
|
|
exec
|
Execute a command in a running container
|
|
up
|
Create and start containers
|
|
up -d
|
Detached mode: Run containers in the background
|
|
stop
|
Stop services
|
|
start
|
Start services
|
|
logs
|
View output from containers
|
|
down
|
Stop and remove containers, networks
|
|
down -v
|
Remove containers, netwRemove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers.orks, volumes
|
|
run -p
|
Publish a container's port(s) to the host
|
|
run --network
|
Connect a container to a network
|
|
network
|
Manage networks
|
|
network create -d
|
Driver to manage the Network: none, bridge, host, overlay, macvlan
|
|
FROM
|
Create a new build stage from a base image
|
|
RUN
|
Execute build commands
|
|
build
|
Build an image from a Dockerfile
|
|
build -t
|
Name and optionally a tag in the name:tag format
|
|
run -v
|
Bind mount a volume
|
|
volume create
|
Create a volume
|
No comments yet.
Cheatography n. The art of mapping complex subjects into clear, instantly navigable reference guides.