We have a docker enabled machine running inside our LAN, but that's no use unless we can run some docker containers. These are going to be the tidy way of providing our services, but the first thing to do is to set up a way to deploy & maintain the docker images & containers.
That's where portainer comes in. It provides a simple web interface for pulling & interacting with containers (& docker volumes), as well as launching containers/docker-compose scripts as "stacks".

I installed it as a docker container. It then manages all the other docker containers (which I'll be going through later on). Obviously you have to install it by hand, since it can't launch itself!

Here's the launch command (separated onto multiple lines so that you can see it clearer).

docker run -d 
-p 9000:9000 
-v /var/run/docker.sock:/var/run/docker.sock 
-v ~/portainer:/data

You can reuse almost all of this "as is", apart from the -v ~/portainer:/data which needs the directory to the left of the ":" to be changed to suit your set up. (Or at least you need to create the portainer directory in your home directory. You could also use a docker data volume (so that you can keep the data persistent when you update the portainer container itself).

Once Portainer is up & running you'll need to do the usual initial setup

  • Use your web browser to go to http://<IP address of the machine you have portainer installed on>:9000
  • Create a password
  • Click on the Docker button to manage the local docker environment
  • Then you can click that big button in the middle of the screen & start exploring

From here on you should be able to pull (download), configure, start & control all of your containers using the portainer interface instead of using the CLI (although you could do that if you wanted!)