Files
docker-compose-cookbooks/portainer/docker-compose.yml
T
2020-04-25 10:40:59 -07:00

38 lines
1011 B
YAML

################################################################################
# Portainer
# You should only need one instance of this running
# Change .env then
# docker-compose up -d
#
# Version 1
################################################################################
version: '2'
volumes:
portainer:
networks:
admin_web:
external:
name: admin_web
services:
portainer:
image: portainer/portainer:${PORTAINER_V}
command: -H unix:///var/run/docker.sock
restart: unless-stopped
networks:
- admin_web
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- portainer:/data
command: -H unix:///var/run/docker.sock
labels:
- "traefik.enable=true"
- "traefik.http.routers.portainer.rule=Host(`${PORTAINER_DOMAIN_NAME}`)"
- "traefik.http.routers.portainer.entrypoints=websecure"
- "traefik.http.routers.portainer.tls.certresolver=letsencrypt"
- "traefik.http.services.portainer.loadbalancer.server.port=9000"