services: traefik: image: {{ traefik_image }} restart: unless-stopped env_file: .env {% if traefik_publish_entrypoints %} ports: - "{{ traefik_bind_address }}:{{ traefik_http_port }}:{{ traefik_http_port }}" - "{{ traefik_bind_address }}:{{ traefik_https_port }}:{{ traefik_https_port }}" {% if traefik_dashboard_enabled %} - "{{ traefik_bind_address }}:{{ traefik_dashboard_port }}:{{ traefik_dashboard_port }}" {% endif %} {% endif %} volumes: - /var/run/docker.sock:/var/run/docker.sock:ro - ./traefik.yml:/etc/traefik/traefik.yml:ro - ./data:/data networks: - {{ traefik_network }} networks: {{ traefik_network }}: external: true