Docker extension for Portainer

Docker extension for Portainer

How to use?

In this article, we will see how to use Portainer extension for Docker Desktop. Does Portainer, Docker extensions sound new? Let's see what are those.

What is Portainer?

Portainer is a lightweight container management system which allows you to manage your container environments like Docker, Kubernetes, Nomad etc.

Portainer is an amazing tool that helps you :

  • to simplify the process of Deployment
  • to manage different containers
  • to manage different endpoints from the same instance.

And one more thing is that it has amazing UI for managing your container environments.

screenzy-1652310067597.png

Why you need Portainer

Let's assume you have many containers running and you want to see the all the containers. We usually do, docker ps -a . we get something like this:

screenzy-1652371337962.png

There's no issue with this , that it doesn't look good.

With Portainer, you can manage all your containers at ease. Portainer provides an amazing GUI that helps you to view/ make changes in your container environment.

screenzy-1652371877563.png

screenzy-1652371946246.png

By using Portainer, I don't have to check the correct syntax for the docker commands. In the portainer UI, you would be able to manage all Docker Objects like Images, containers, networks, volumes.

What is Docker Extension?

Docker Extensions are the feature that lets you use third-party tools within Docker Desktop to extend its functionality. You can install many number of Docker extensions. Docker Extensions is available as part of Docker Desktop 4.8.0 or a later release.

Install Portainer Docker Extension:

  • Open Docker Desktop.
  • From the Dashboard, select Add Extensions in the menu bar. The Extensions Marketplace opens.
  • Browse for the Portainer extensions.
  • Click Install.
  • From here, you can click Open to access the extension or install more extensions. The extension also appears in the menu bar.

annotely_image.png

annotely_image(1).png

Manage your local Docker environment

Once you install the portainer extension, the homepage would look like this.

screenzy-1652387104624.png Click on "Get Started" to see your container environments. You can also add many environments with different properties.

screenzy-1652387119996.png When you click on the environment, you can get detailed information about the environment and it properties.

screenzy-1652387270207.png

Deploy Nginx using Portainer Extension

Let's try to deploy the "nginx" using the GUI provided by Portainer. In Portainer GUI, click on 'Containers' and the click on 'Add Container'.

annotely_image(2).png

  1. Give your Container a name. Ex: my-nginx-server
  2. Specify the image you want to use. By default, Portainer use Docker Hub as image repository from which it fetches the images.
  3. We want is to access our nginx server from our browser and for that we need to expose a port. Here we exposed container Port 80 to external port 8080
  4. Deploy the container

annotely_image(3).png

The above steps we performed is like the docker command

docker run --name my-nginx-server -p 8080:80 nginx

Nginx is now deployed and is exposing to port 8080. Now let us head over to the browser (localhost:8080) and see if our nginx is running or not.

screenzy-1652388721874.png

Managing Docker Objects

By using Portainer GUI, We can start, stop, restart, remove one or more containers and create new ones.

You can also see the logs of the containers, Inspect them, stats and also access the console of the container.

annotely_image(5).png

By using Portainer , you can manage all Docker Objects like Images, containers, networks, volumes.

Conclusion

Portainer is an awesome tool that is used to maintain Docker containers, Kubernetes, Azure ACI and other container environments with an easy-to-use interface. It simplifies the Container management by reducing the usage of complex commands by using its clickable interface. For more, visit Portainer.io

Did you find this article valuable?

Support Srinivas Karnati by becoming a sponsor. Any amount is appreciated!