I'm running Traefik on a Raspberry Pi 5 with the following docker-compose.yml configuration:
networks:
frontend:
name: frontend
volumes:
traefik_acme:
name: traefik_acme
services:
traefik:
image: "traefik:v3"
container_name: "traefik"
restart: unless-stopped
security_opt:
- no-new-privileges:true
ports:
- "80:80"
- "443:443"
- "8080:8080"
environment:
- CF_API_EMAIL=${CF_API_EMAIL}
- CF_DNS_API_TOKEN=${CF_DNS_API_TOKEN}
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- traefik_acme:/letsencrypt
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
networks:
- frontend
command:
- --api.dashboard=true
- --log.level=INFO
- --accesslog=true
- --providers.docker=true
- --providers.docker.exposedByDefault=false
# Configuração do EntryPoint HTTP para Redirecionamento
- --entrypoints.web.address=:80
- --entrypoints.web.http.redirections.entrypoint.to=websecure
- --entryPoints.web.http.redirections.entrypoint.scheme=https
# Configuração do EntryPoint HTTPS Seguro
- --entrypoints.websecure.address=:443
- --entrypoints.websecure.asDefault=true
- --entrypoints.websecure.http.tls=true
- --entrypoints.websecure.http.tls.certresolver=le
# Configuração do Resolvedor ACME via Cloudflare DNS Challenge
- --certificatesresolvers.le.acme.email=${CF_API_EMAIL}
- --certificatesresolvers.le.acme.storage=/letsencrypt/acme.json
- --certificatesresolvers.le.acme.dnschallenge=true
- --certificatesresolvers.le.acme.dnschallenge.provider=cloudflare
labels:
- traefik.enable=true
- traefik.http.routers.dashboard.rule=Host(`traefik.${DOMAIN}`)
- traefik.http.routers.dashboard.entrypoints=websecure
- traefik.http.routers.dashboard.service=api@internal
- traefik.http.routers.dashboard.middlewares=secure-auth
- traefik.http.middlewares.secure-auth.basicauth.users=${BASIC_AUTH}
traefik_dynamic.yml content:
http:
middlewares:
https-only:
redirectScheme:
scheme: https
dashboard-auth:
basicAuth:
users:
- '${BASIC_AUTH}'
My problem is that whenever I access any address on the domain, it takes almost a minute to load.
I've already tried monitoring the logs (docker logs traefik --timestamps -f) but haven't found anything helpful. It only displays the request log itself.
Any tips on what might be wrong or any additional logs I could review to try and find the cause of the slowness?