Search code examples
dockeryamlswarm

docker stack (swarm) not working but docker-compose ok


I have my test service working in docker-compose but not in swarm :/

version: "3.3"

services:

  traefik:
    image: "traefik:v2.2"
    command:
      #- "--log.level=DEBUG"
      - "--api.insecure=true"
      - "--providers.docker=true"
      - "--providers.docker.exposedbydefault=false"
      - "--entrypoints.web.address=:80"
    ports:
      - "80:80"
      - "8080:8080"
    volumes:
      - "/var/run/docker.sock:/var/run/docker.sock:ro"

  whoami:
    image: "containous/whoami"
    labels:
      - "traefik.enable=true"
      - "traefik.http.routers.whoami.rule=Host(`myurl.com`)"
      - "traefik.http.routers.whoami.entrypoints=web"

Someone have an idea on my issue ? It's like if there is an issue network only in swarm mode and note in docker-compose.


Solution

  • I was on old image of archlinux which is the most recent of a big french three letter networking company. With a kernel up to date all seems to be good now.