Hi community,
I try to use traefik version 2. I consult the documentation provided and in the end I can not access the net from the application container.
docker-compose.yml
version: "3.3"
services:
traefik:
image: "traefik:v2.0.1"
command:
- --entrypoints.web.address=:80
- --providers.docker
- --api.insecure
ports:
- "80:80"
- "8080:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
my-app:
image: containous/whoami:v1.3.0
labels:
- "traefik.http.routers.my-app.rule=Host(`whoami.monndd.com`)"
- "traefik.http.routers.my-app.middlewares=auth"
- "traefik.http.middlewares.auth.basicauth.users=user:$$apr1$$q8eZFHjF$$Fvmkk//V6Btlaf2i/ju5n/"
When I want to access the traefik container with the ip of my server on port 8080 it works well. By cons, when the spear "whoami.monndd.com" I get error "504 bad gateway".