DEV Community

Cover image for GUI to Docker Containers
Visakh Vijayan
Visakh Vijayan

Posted on

GUI to Docker Containers

One of the main things you would like to do when you are running Docker containers is communicating with them. Although there are tools like kitematic which provide a GUI interface to use docker, we still somehow stick to the CLI version.

Docker in brief

In brief, a container is an encapsulated version of your source code along with its dependencies. Think of it as a box of the good stuff which will run everywhere. The host OS talks to the container which in turn allows you to access it via the host OS.

Start by showing all containers in your system at present -

docker container ls
Enter fullscreen mode Exit fullscreen mode

The leftmost part will show you the Container Ids

Now, what if you want to access it directly. Sure there are CLI commands for that - one such being

docker exec -it <containerId> bash
Enter fullscreen mode Exit fullscreen mode

But how about a GUI client. Well below is a small workaround.

docker inspect <containerId>
Enter fullscreen mode Exit fullscreen mode

This gives you a json as follows

Mongo Container

What you will need is the IPAddress part. Just copy that IP address and go to your GUI client and paste it there.

robomongo

For eg. I was using a mongo container in the above picture. And below is a screen of the robomongo GUI connecting to the container.

Robo connected

I hope it helps!

PS: Use the VSCode's awesome docker extension. Makes life super easy

Happy coding :D
Stay safe everyone

Top comments (2)

Collapse
 
shortnewsweb1 profile image
shortnewsweb

Docker Desktop Dashboard has been introduced in the latest release of Docker Desktop. It provides a simple interface that enables you to interact with containers and applications and manage the lifecycle of your applications directly from your machine.

You can find all other best tools options in detail here:

ny55.blogspot.com/2020/06/gui-for-...

Collapse
 
digital_hub profile image
hub

this rocks - this is so cool. Many thanks for sharing.