title: how to use host network config using docker-compose
body: <p>I'm trying to use server(host) network setting for docker container also. I'm able to do it using docker run command but not able to do it using docker-compose.
  I'm trying to achieve same behaviour as the command -</p>
  <p><code>sudo docker run -p 8001:8001 -d --network host --name container_name image_name</code></p>
  <p>using docker-compose. All the solution I found in internet are not working.</p>
  <p>here is my docker-compose.yml</p>
  <pre><code>version: '3.4'
  
  services:
  
      e-si:
          build: ./path/to/project
          networks : host
          ports:
              - 8001:8001
          volumes:
              - /server/location:/container/location
  </code></pre>
  <p>Can anyone tell me what I'm doing wrong?</p>
  <p>Thanks in advance.</p>