I moved from latest to v3.0 and I have lost my certs as well as the dashboard. Routes are working and registering correctly (failing tls obviously).
Just to head off any "why don't you use letsencrypt". My domain is internal and cannot be a public DNS and I rather use my own long lived cert".
$ curl -k http://docker.basement.lab
Moved Permanently
$ curl -k https://docker.basement.lab
404 page not found
$ curl -k http://docker.basement.lab:8080/dashboard/dashboard/#/
404 page not found
$ curl -k https://docker.basement.lab:8080/dashboard/dashboard/#/
404 page not found
ssl error (it's the same wildcard cert that was being used for v2):
2024-05-02T10:26:43-04:00 DBG github.com/traefik/traefik/v3/pkg/tls/tlsmanager.go:228 > Serving default certificate for request: "docker.basement.lab"
2024-05-02T10:26:43-04:00 DBG log/log.go:245 > http: TLS handshake error from 192.168.1.10:13305: remote error: tls: bad certificate
2024-05-02T10:26:46-04:00 DBG github.com/traefik/traefik/v3/pkg/tls/tlsmanager.go:228 > Serving default certificate for request: "docker.basement.lab"
2024-05-02T10:27:20-04:00 DBG github.com/traefik/traefik/v3/pkg/tls/tlsmanager.go:228 > Serving default certificate for request: "bookstack.basement.lab"
2024-05-02T10:27:20-04:00 DBG log/log.go:245 > http: TLS handshake error from 192.168.1.10:13321: remote error: tls: bad certificate
docker-compose:
name: traefik
services:
traefik:
container_name: traefik
volumes:
- /etc/localtime:/etc/localtime:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
- /home/portainer/traefik/certs:/certs
- /home/portainer/traefik/config/traefik.yml:/traefik.yml:ro
- /home/portainer/traefik/config/config.yml:/config.yml:ro
- /home/portainer/traefik/logs:/logs
security_opt:
- no-new-privileges:true
networks:
- traefik_default
ports:
- 443:443
- 80:80
- 8080:8080
restart: unless-stopped
labels:
- traefik.enable=true
- traefik.http.routers.dashboard.rule=Host(`docker.basement.lab`) && (PathPrefix(`/api`) || PathPrefix(`/dashboard`))
- traefik.http.routers.dashboard.entrypoints=websecure
- traefik.http.routers.dashboard.service=dashboard@internal
- traefik.http.routers.traefik.rule=Host(`docker.basement.lab`)
- traefik.http.routers.traefik_https.entrypoints=websecure
- traefik.http.routers.traefik_https.tls=true
- traefik.http.middlewares.traefik-https-redirect.redirectscheme.scheme=https
- traefik.http.middlewares.sslheader.headers.customrequestheaders.X-Forwarded-Proto=https
- traefik.http.routers.traefik.middlewares=traefik-https-redirect
- traefik.http.routers.traefik-secure.entrypoints=https
- traefik.http.routers.traefik-secure.rule=Host(`docker.basement.lab`)
- traefik.http.routers.traefik-secure.middlewares=traefik-auth
- traefik.http.routers.traefik-secure.tls=true
- traefik.http.routers.traefik-secure.tls.domains[0].main=basement.lab
- traefik.http.routers.traefik-secure.tls.domains[0].sans=*.basement.lab
- traefik.http.routers.traefik-secure.service=api@internal
logging:
options:
gelf-address: tcp://graylog.basement.lab:12201
driver: gelf
runtime: runc
image: docker.io/traefik:latest
command: traefik
networks:
traefik_default:
external: true
name: traefik_default
The config file:
global:
checkNewVersion: true
sendAnonymousUsage: false
serversTransport:
rootCAs:
- ca_cert.crt
log:
level: DEBUG
filePath: "/logs/traefik.log"
api:
dashboard: true
insecure: false
debug: false
ping: {}
tls:
options:
default:
defaltCertificate:
- certFile: /home/portainer/traefik/certs/wildcard_cert.pem
keyFile: /home/portainer/traefik/certs/wildcard_key.pem
certificates:
- certFile: /home/portainer/traefik/certs/wildcard_cert.pem
keyFile: /home/portainer/traefik/certs/wildcard_key.pem
entryPoints:
web:
address: ":80"
http:
redirections:
entryPoint:
to: websecure
scheme: https
websecure:
address: :443
forwardedHeaders:
trustedIPs:
- "127.0.0.1/32"
- "192.168.1.0/24"
#serversTransport:
# insecureSkipVerify: true
providers:
docker:
defaultRule: "Host(`{{ normalize .Name }}.basement.lab`)"
endpoint: "unix:///var/run/docker.sock"
exposedByDefault: false
network: traefik_default