Docker

From The World according to Vissie
Jump to navigation Jump to search

Setup

https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-debian-10

Setup docker-compose

sudo curl -L "https://github.com/docker/compose/releases/download/1.26.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose

Setup Portainer

https://www.portainer.io/installation/
docker volume create portainer_data
docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer

Some common tasks

Run a new container

docker run -d -p 172.17.0.3:8888:8888 --restart unless-stopped --name rainloop /rainloop

Add restart policy

docker update --restart unless-stopped rain_loop