Here are some basic commands used in docker. Hope it helps you.
docker build -t image_tag_name .
.
] indicated the current folder where file named Dockerfile isdocker images
docker run -it --name container_name_here image_tag_name
-it
: It will open interactive terminal after running it, to interact with containerdocker exec -it container_name shell[/bin/bash]
docker exec -it debian /bin/bash
docker start container_name
docker start -i container_name
List all container: docker ps -a
List all running container: docker ps
docker inspect container_name| grep IPAddress
Renaming the docker : docker rename old_container_name new_container_name
docker rm -f container_name
-f
flag.docker rm $(docker ps --filter "status=exited" -q)
docker rmi image_name
docker run -p <host_port>:<container_port> -p <host_port>:<container_port> -d -it --name container_name image-name