Credit: www.portainer.io
Docker is a fantastic tool, enabling you to run all kinds of applications, tools and services in selfcontained spaces without the need for a fullblown virtual machine. But controlling it from the command line can be tricky. The obvious solution when running Docker on a desktop is to pair it with Docker Compose, the official GUI frontend, but what if you don’t like Docker Compose, or you’re running Docker on a server with no desktop?
The answer lies in Portainer (www.portainer.io) – a web-based frontend you can use to control Docker from any PC on your local network – or even further afield if you pair it with a reverse proxy. Portainer’s user-friendly interface is packed with powerful features to make it a worthy alternative to Docker Compose. It can be used to manage all the instances of Docker across your network from one central place, and also works with Docker Swarm, Kubernetes and Nomad. Portainer comes in both free and paid-for editions – we’ll be focssing on the free Community Edition version in this tutorial.
Installing Portainer
We’re assuming you already have a form of Docker installed on your machine – see https://docs.docker.com/engine/install/ubuntu for details of installing it in Ubuntu if not. Portainer ships as a Docker instance – it can be run as part of a Docker Swarm or in Kubernetes (see https://docs.portainer.io/v/ce-2.11/start/install for details), but for the purposes of this tutorial, we’ll focus on running it with a local instance of Docker.
To do this, issue these commands in the Terminal, which assume you’ve either added your username to the docker group or configured for rootless access. If not, prefix the commands using sudo.