Docker Commands

#see running containers
docker ps
#kill a running container (use CONTAINER ID)
docker kill d4930c9b409a
#list all images
docker images -a
#remove an image (use IMAGE ID)
docker rmi -f 3dcfe809147d

#run without connecting into bashdocker command

#start the container in an interactive mode -i -t. In our case, we will override the entrypoint command so we are presented with a bash terminal. Now we can execute whatever commands we want, but exiting the container will stop it

docker run -i -t –entrypoint=”bash” imagename


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: