# Docker Swarm - Get Real IP from Container

**URL:** <https://community.traefik.io/t/docker-swarm-get-real-ip-from-container/4024>\
**Category:** Traefik v2\
**Tags:** docker-swarm\
**Created:** [January 20, 2020, 8:29pm UTC](https://community.traefik.io/t/docker-swarm-get-real-ip-from-container/4024 "2020-01-20T20:29:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![akramfares](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/akramfares/32/1175_2.png) [@akramfares](https://community.traefik.io/u/akramfares)\
**Post date:** [January 20, 2020, 8:29pm UTC](https://community.traefik.io/t/docker-swarm-get-real-ip-from-container/4024/1 "2020-01-20T20:29:04Z")

</div>

Hi,

I have a Docker Swarm behind an AWS ELB. Traefik and a service displaying HTTP Headers are running.  
Here is my config:

```auto
version: "3.3"
services:
  traefik:
    image: traefik:2.1
    command: 
      - "--providers.docker=true" 
      - "--providers.docker.swarmmode=true"
      - "--providers.docker.exposedbydefault=false"
      - "--entrypoints.web.address=:80"
      - "--entryPoints.web.forwardedHeaders.insecure"
      - "--entryPoints.web.proxyProtocol.insecure"
      - "--entrypoints.web.transport.respondingtimeouts.idletimeout=0"
      - "--serverstransport.forwardingtimeouts.dialtimeout=0"
      - "--log.level=INFO"
      - "--log.filePath=/var/log/traefik/access.log"
    ports:
      - "80:80"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
    labels:
      - "traefik.enable=false"
    networks:
      - public
    deploy:
      mode: global
      placement:
        constraints:
          - node.role == manager
networks:
  public:
    driver: overlay

```

The HTTP Headers service

```auto
debugheaders:
    image: mendhak/http-https-echo
    deploy:
      replicas: 1
      labels:
        - traefik.enable=true
        - "traefik.http.services.debugheaders.loadbalancer.server.port=80"
        - "traefik.http.routers.debugheaders.rule=Host(`test.com`)"
        - "traefik.http.routers.debugheaders.priority=0"
        - "traefik.http.services.debugheaders.loadbalancer.sticky=true"
        - "traefik.docker.network=public"
      placement:
        constraints: [node.role==worker]
    networks:
      - public

```

The issue is I'm not getting the Real IP in the X-Forwarded-For header, what I am missing?

Thanks
