Files
homelab/portainer/compose.yaml
T
forust fb2f420520 refactor: update network refs form "traefik-proxy" to "proxy"
- To allow testing dev vers of other services
2025-12-30 14:14:24 +01:00

55 lines
2.1 KiB
YAML

services:
portainer:
container_name: portainer
image: portainer/portainer-ce:latest
restart: always
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./portainer_data:/data
ports:
- 9443:9443
# - 8000:8000 # Remove if you do not intend to use Edge Agents
networks:
- proxy
labels:
- "traefik.enable=true"
- "traefik.docker.network=proxy"
# Prod Router
- "traefik.http.routers.portainer.rule=Host(`portainer.forust.xyz`)"
- "traefik.http.routers.portainer.entrypoints=websecure"
- "traefik.http.routers.portainer.middlewares=security-headers@file"
- "traefik.http.routers.portainer.service=portainer"
- "traefik.http.routers.portainer.tls=true"
- "traefik.http.services.portainer.loadbalancer.server.port=9443"
- "traefik.http.services.portainer.loadbalancer.server.scheme=https"
- "traefik.http.services.portainer.loadbalancer.serverstransport=insecureTransport@file"
# Local Router
- "traefik.http.routers.portainer-local.rule=Host(`portainer.workstation.internal`) || Host(`portainer.internal`)"
- "traefik.http.routers.portainer-local.entrypoints=websecure"
- "traefik.http.routers.portainer-local.middlewares=security-headers@file"
- "traefik.http.routers.portainer-local.service=portainer"
- "traefik.http.routers.portainer-local.tls=true"
# Dev Router
- "traefik.http.routers.portainer-dev.rule=Host(`portainer.gigaforust.internal`)"
- "traefik.http.routers.portainer-dev.entrypoints=websecure"
- "traefik.http.routers.portainer-dev.middlewares=security-headers@file"
- "traefik.http.routers.portainer-dev.service=portainer"
- "traefik.http.routers.portainer-dev.tls=true"
- glance.name=Portainer
- glance.url=https://portainer.forust.xyz/
- glance.description=Portainer is a lightweight management UI which allows you to easily manage your Docker environments.
volumes:
portainer_data:
name: portainer_data
networks:
default:
name: portainer_network
proxy:
external: true