# Getting 404 for Docker Swarm + Traefik v2

**URL:** <https://community.traefik.io/t/getting-404-for-docker-swarm-traefik-v2/2561>\
**Category:** Traefik v2\
**Tags:** docker-swarm, docker\
**Created:** [October 23, 2019, 6:45pm UTC](https://community.traefik.io/t/getting-404-for-docker-swarm-traefik-v2/2561 "2019-10-23T18:45:11Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rabelais88](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/rabelais88/32/982_2.png) [@rabelais88](https://community.traefik.io/u/rabelais88)\
**Post date:** [October 23, 2019, 6:45pm UTC](https://community.traefik.io/t/getting-404-for-docker-swarm-traefik-v2/2561/1 "2019-10-23T18:45:12Z")

</div>

I've tried ask question on this forum [last time](https://community.containo.us/t/unable-to-obtain-https-acme-certification-for-a-docker-microservice-with-subdomains/1428) but couldn't get any help. This led me to scrap everything and to start from beginning again.

I am writing a new compose file with `traefik.yaml` with very simple setting. Unfortunately Traefik isn't routing any request correctly and just showing default 404 pages. I wish I could get at least a some sort of log, but it doesn't even yield any logs. I am literally plucking my hair out.

```auto
# traefik.yaml
providers:
  docker:
    # endpoint: "tcp://127.0.0.1:2375"
    endpoint: "unix:///var/run/docker.sock"
    swarmMode: true
    network: test-app_web-internal

api:
  dashboard: true # must access it via url:${HOSTNAME}/dashboard/
  # insecure: true # only for dev mode
  debug: true
log:
  level: DEBUG

entryPoints:
  web:
    address: ":80"
  web-secure:
    address: ":443"

```

```auto
# docker-compose.yaml
version: '3.7'
services:
  proxy-traefik:
    image: traefik:latest
    volumes:
      - "./traefik/traefik.dev.yaml:/etc/traefik.yaml"
      - "/var/run/docker.sock:/var/run/docker.sock"
    ports:
      - "80:80"
      - "433:433"
      - "8080:8080" # dashboard
    deploy: # specify configuration for services(not container)
      labels: 
        - traefik.http.routers.proxy-traefik.rule=Host('traefik.127.0.0.1.xip.io')
        - traefik.http.services.proxy-traefik.loadbalancer.server.port=8080
        - traefik.docker.network=web-internal
      placement:
        constraints:
          - node.role == manager
        preferences:
          - spread: node.id
    networks:
      - web-internal

  front:
    image: test-app-dev_front:latest
    ports: # FOR DEBUG PURPOSE - must be disabled in PROD
      - "3000:3000"
    deploy:
      labels:
        - traefik.http.routers.web-traefik.rule=Host('127.0.0.1.xip.io')
        - traefik.http.routers.web-traefik.entrypoints=web # open to :80,443
        - traefik.http.services.web-traefik.loadbalancer.server.port=3000
        - traefik.docker.network=web-internal
        - traefik.enable=true
    volumes:
      - "./frontend/src:/node/myapp/src"
      - "./frontend/public:/node/myapp/public"
    networks:
      - web-internal

networks:
  web-internal:
    name: web-internal
    driver: overlay # allows contact different nodes
    # attachable: true # outside container can be attached to this network
volumes:
  front-node_modules:

```

---

<div class="post-metadata">

**Author:** ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)\
**Post date:** [October 23, 2019, 10:49pm UTC](https://community.traefik.io/t/getting-404-for-docker-swarm-traefik-v2/2561/2 "2019-10-23T22:49:39Z")

</div>

Hello,

you have to use back-ticks instead of single quote in the rule definition:

```auto
traefik.http.routers.proxy-traefik.rule=Host(`traefik.127.0.0.1.xip.io`)

```
