Skip to main content

Creating Your First Container

https://docs.portainer.io/start/install-ce/server/docker/linux

Need to use sudo to get access to docker socket.

sudo docker volume create portainer_data

Will return name of container.

sudo docker run -d -p 8000:8000 -p 9000:9000 -p 9443:9443 --name portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:2.21.5

This adds port 9000, which isn't used by default.  This allows Portainer to be accessed through HTTP instad of HTTPS.

Docker will download the image and start the container.

docker ps

Go to localhost:9000

 

Create administrator account.  This can time out if you do not do it right away.  This will require stopping and restarting the portainer container.

Hit Get Started to use the default docker environment.