Bootstrap
<FreeKB>
Home
About
Walkthroughs
Docker
Profile
Sign in
FreeKB Articles
Docker articles
Authentication
get auth_token using REST API
CMD
Run a command in a container using the docker exec command
Run a command in a container using the docker run command
containers
Add user to a container using the useradd or adduser command
Copy file between container and host using the docker cp command
Delete a container using the docker rm command
Display container details using the docker inspect container command
List containers using the docker container ls command
List processes using the docker ps command
Present working directory
Rename a container using the docker rename command
Restart a container using the docker restart command
Start a container using the docker start command
Stop a container using the docker stop command
docker compose
docker-compose version command
install docker-compose on Linux
docker run command
Append entries to the /etc/hosts file in a container using the docker run --add-host command
Assign a name to a container using the docker run --name command
Assign an IP address to a container using the docker run --ip command
Assign DNS servers to a container using the docker run --dns command
Choose the network that the container will use using the docker run -n or --network command
Create or start a container without IPv6
Define environment variables in a container using the docker run -e or --env command
Define the hostname of a container using the docker run -h or --hostname command
Get an interactive shell into a container using the docker run -it or --interactive and -t or --tty commands
Getting Started with the docker run command
Open ports in a container using the docker run -p or --publish command
Remove container using the docker run --rm command
Restart a container using the docker run --restart option
Run container in background using the docker run --detach command
Dockerfile
Build an image using a Dockerfile
Define environment variables in Dockerfile using ENV
EXPOSE ports in Dockerfile
Run a command using CMD in Dockerfile
Run as using USER in Dockerfile
Events
docker events command
images
Create a new image from existing image using the docker commit command
Create your first Hello World container image
Delete an image using the docker rmi command
Display image details using the docker image inspect command
docker search command
Download an image using the docker pull command
List images using the docker images command
Pull an image and create a container using the docker create command
Push an image to Docker Hub
Tag an image using the docker tag command
Upload an image to a registry using the docker push command
Images
Remove unused containers images volumes using the docker system prune command
Install
Install Docker on Linux
Install Docker on Linux Red Hat
Install Docker on Windows
uninstall Docker on Linux CentOS
Login
Log into docker.io Docker Hub using the docker login command
Logs
docker logs command
Networking
connect a container to a network using the docker network command
Create a network using the docker network create command
Delete a network using the docker network rm command
Delete a network using the docker network rm command
Display network details using the docker network inspect command
List networks using the docker network ls command
registry
display images in a private registry using REST API
Install a Docker Registry
root directory
Set Docker root directory using root-data in daemon.json
Secrets
delete secret using REST API
Delete secrets using the docker secret rm command
docker secret create command
docker secret inspect command
list secrets using REST API
List secrets using the docker secret ls command
list secrets using the Docker Universal Control Panel
Services
Delete services using the docker service rm command
Inspect service using the docker service inspect command
List services using the docker service ls command
Restart service using the docker service scale command
Stack
Create stacks using the docker stack deploy command
Delete stacks using the docker stack rm command
docker restart stack service
List services in a stack using the docker stack services ls command
List stacks using the docker stack ls command
Start Stop Restart
start stop restart Docker on Linux
Swarm
docker swarm init command
Troubleshooting
Resolve "EACCES permission denied"
Resolve "error while creating mount source path"
Resolve "failed to create Cloudwatch log stream: NoCredentialProviders"
Resolve "MariaDB Connector/Python requires MariaDB Connector/C"
Resolve "mkdir cannot create directory permission denied"
Version
docker version command
Volumes (storage)
Create a volume using the docker volume command
Mount a file or directory in a container using the docker run -m or --mount command
Mount a file or directory in a container using the docker run -v or --volume command