Traefik dashboard not reachable

33 Views Asked by At

While trying to setup a Traefik (2.10.4) reverse-proxy the dashboard doesn't want to goes up.
May anyone help me ? Spent the whole night on it without success x(
Still getting an 404 Not found...

The OS is a Ubuntu 23.04 with a Docker version 24.0.6

Thanks a lot !

=== Tech Details ===

Docker networks:

NETWORK ID     NAME      DRIVER    SCOPE
[...]
7e5ddb244213   web       bridge    local

Arborescence:

.
|-- data
|   |-- acme.json
|   |-- data
|   |-- logs
|   |-- providers
|   `-- traefik.toml
|-- docker-compose.yml
|-- logs
|   |-- access.log
|   `-- traefik.log
`-- providers
    `-- dashboard.toml

docker-compose.yaml:

# /apps/traefik/docker-compose.yml
version: '3'

services:
  reverse-proxy:
    image: traefik:v2.10.4
    container_name: traefik
    ports:
      - "80:80"
      - "443:443"
      - "8080:8080"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - $PWD/data:/etc/traefik
      - $PWD/providers:/providers
      - $PWD/logs:/var/log/traefik
    restart: always
    networks:
      - web
networks:
  web:
    external: true

traefik.toml

# /apps/traefik/traefik.toml
[api]
  dashboard = true
  insecure = false

[entryPoints]
  [entryPoints.web]
    address = ":80"
    [entryPoints.web.http]
      [entryPoints.web.http.redirections]
        [entryPoints.web.http.redirections.entryPoint]
          to = "websecure"
          scheme = "https"
          permanent = true

  [entryPoints.websecure]
    address = ":443"
      [entryPoints.websecure.http.tls]
        certResolver = "default"

  [entryPoints.api]
    address = ":8000"

[providers]
  [providers.docker]
    watch = true
    exposedByDefault = false
    network = "web"
  [providers.file]
    directory = "/providers/"
    watch = true

[log]
  filePath = "/var/log/traefik/traefik.log"
  level = "DEBUG"

[accessLog]
  filePath = "/var/log/traefik/access.log"

[certificatesResolvers]
  [certificatesResolvers.default]
    [certificatesResolvers.default.acme]
      email = "[email protected]"
      storage = "/etc/traefik/acme.json"
      caServer = "https://acme-v01.api.letsencrypt.org/directory"
    [certificatesResolvers.default.acme.tlsChallenge]

provider.toml:

[http]
  [http.routers]
    [http.routers.secure-api-dashboard]
      entryPoints = ["api"]
      service = "api@internal"
      middlewares = ["secure-internal"]
      rule = "Host(`traefik.domain.com`) && PathPrefix(`/api`, `/dashboard`)"

  [http.middlewares]
    [http.middlewares.secure-internal.basicAuth]
    users = [
    "admin:$apr1$sSRuZK1Q$7vzfwB5VcQfmDLLTP31pj1",
    ]
0

There are 0 best solutions below