|
docker ps
|
List of live containers
|
|
docker ps -a
|
List all containers
|
|
docker info
|
Retrieves docker configuration
|
|
docker version
|
Retrieves docker versioning
|
|
docker build -t <Image>:<Tag> .
|
Builds a docker Image from Dockerfile or container
|
|
docker push <Image_Name>:<Tag>
|
Pushes the image to the repo
|
|
docker pull<Image_Name>:<Tag>
|
Pulls the image from the repo
|
|
docker inspect <Container>
|
Inspect a container
|
|
docker stats <Container>
|
Live data stream from container
|
|
docker logs <Container>
|
Retrieves the containers logs
|
|
docker run <Container>
|
Run container
|
|
docker kill <Container>
|
Kill a running container
|
|
docker start <Container>
|
Start container
|
|
docker stop <Container>
|
Stop a running container
|
|
docker restart <Container>
|
Restarts the container
|
|
docker rm <Container>
|
Remove container
|
|
docker port <Container>
|
Lists the port mapping of the container
|
|
docker pause <Container>
|
Suspends all the processes in the container
|
|
docker unpause <Container>
|
Un-suspends all the processes in the container
|
|
docker volume ls
|
List volumes
|
|
docker volume inspect <Volume>
|
Inspect volume
|
|
docker volume create <Volume>
|
Create volume
|
|
docker volume rm <Volume>
|
Removes a volume
|
|
docker cp <Container>:<source_path> <dest_path>
|
Copy from container to host
|
|
docker cp <source_path> <Container>:<dest_path>
|
Copy from host to container
|
|
docker exec -ti <Container> <Entrypoint>
|
Executes the terminal of a live container
|
|
-p, –-publish
|
Host to container port mapping
|
|
--publish-all
|
Publish all ports
|
|
--expose
|
Expose container port
|
|
-d, –-detach
|
Run in background
|
|
-e, –-env
|
set env vars
|
|
-v, --volume
|
Mount files or directories
|
|
-i, --interactive
|
|
|
-t, --tty
|
|
|
exec
|
Run a new command in a container
|
|
cp
|
copy path
|
|
docker images
|
List images
|
|
docker run <Image>
|
runs the image
|
|
docker create <Image>:<Tag>
|
Create image
|
|
docker rmi <Image>
|
Remove image
|
|
docker save <Image>
|
Saves images to a tar archive
|
|
docker network ls
|
List networks
|
|
docker network inspect <Network>
|
Inspect a network
|
|
docker network create <Network>
|
Create a network
|
|
docker network rm <Network>
|
Removes a network
|
|
docker network connect <Network> <Container>
|
Connect a container to the network
|
|
docker network connect --ip <IP> <Network> <Container>
|
Specify the ip address of container interface
|
|
docker network disconnect <Network_Name> <Container>
|
Disconnect container from network
|
No comments yet.
Cheatography n. The art of mapping complex subjects into clear, instantly navigable reference guides.