Using Docker Desktop to manage a Container
Once you start a Docker container, if you go and click the Docker icon in the toolbar and choose Dashboard, you will see it in Docker Desktop:

Now if you hover the container with the mouse, you will see 5 buttons:

They are:
- Open in browser
- CLI
- Stop
- Restart
- Delete
You can manage your container lifecycle through them.
Clicking a container name in the list will reveal more data, including a Logs manager:

An inspector that tells you useful information about the container:

And stats about the container CPU, Memory, Network and Disk usage:

Go back and click the Open in browser button and the http://localhost/tutorial URL will open (http://localhost redirects to http://localhost/tutorial in this app):

This is the content of a website that’s provided by our sample image. Now go back to Docker Desktop and press the Stop button

and refresh the page, it does not work any more:

Go back to Docker Desktop and press the Start button, it will work again.
Try pressing the CLI button. A new terminal window will open and you will automatically be connected to the Docker Container, as the root user:

In the above picture the whoami command returns the current user name.
download all my books for free
- javascript handbook
- typescript handbook
- css handbook
- node.js handbook
- astro handbook
- html handbook
- next.js pages router handbook
- alpine.js handbook
- htmx handbook
- react handbook
- sql handbook
- git cheat sheet
- laravel handbook
- express handbook
- swift handbook
- go handbook
- php handbook
- python handbook
- cli handbook
- c handbook
subscribe to my newsletter to get them
Terms: by subscribing to the newsletter you agree the following terms and conditions and privacy policy. The aim of the newsletter is to keep you up to date about new tutorials, new book releases or courses organized by Flavio. If you wish to unsubscribe from the newsletter, you can click the unsubscribe link that's present at the bottom of each email, anytime. I will not communicate/spread/publish or otherwise give away your address. Your email address is the only personal information collected, and it's only collected for the primary purpose of keeping you informed through the newsletter. It's stored in a secure server based in the EU. You can contact Flavio by emailing [email protected]. These terms and conditions are governed by the laws in force in Italy and you unconditionally submit to the jurisdiction of the courts of Italy.