traefik

Docker - Traefik

Docker Traefik Example cat << EOF > docker-compose.yml version: "3.3" services: traefik: image: "traefik:v2.9" container_name: "traefik" command: # Traefik Log - "--log.level=DEBUG" - "--log.filePath=/logs/traefik.log" - "--api.insecure=true" - "--api.dashboard=true" - "--providers.docker=true" - "--providers.docker.exposedbydefault=false" - "--entrypoints.web.address=:80" # Access Log - "--accesslog=true" - "--accesslog.filePath=/logs/access.log" # Prometheus metrics ## Enable prometheus metrics - "--metrics.prometheus=true" ## Create a manual router instead of the default one. - "--metrics.prometheus.manualrouting=true" - "--metrics.prometheus.addrouterslabels=true" ports: - "80:80" - "8080:8080" volumes: - "/var/run/docker.