Skip to content

2023

Relative Paths with Docker and Portainer

I run docker workloads at home through Portainer. Some time ago I wanted to standardize on Docker Compose to manage container definitions via code, rather than configuring containers by hand in Portainer. Luckily, Portainer has the concept of "stacks", just their way of handling Docker Compose. Stacks can be used a few ways in Portainer, configured directly in Portainer or referenced from a Git repository, such as Gitlab. This is an attractive feature, even for a homelab, as it allows built in version control of your Docker Compose file, with a built in backup (sort of)!