docker / for-win

Bug reports for Docker Desktop for Windows
https://www.docker.com/products/docker#/windows
1.86k stars 289 forks source link

'--network host' based containers not accessible. #5001

Closed scyto closed 4 years ago

scyto commented 4 years ago

https://hub.docker.com/editions/community/docker-ce-desktop-windows -->

Expected behavior

docker run -it --rm --network host name/image:tag should result in machines accessible from LAN

Actual behavior

container not accessible from LAN or from localhost

Information

Server: Containers: 10 Running: 8 Paused: 0 Stopped: 2 Images: 6 Server Version: 19.03.3 Storage Driver: overlay2 Backing Filesystem: extfs Supports d_type: true Native Overlay Diff: true Logging Driver: json-file Cgroup Driver: cgroupfs Plugins: Volume: local Network: bridge host ipvlan macvlan null overlay Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog Swarm: active NodeID: qnspxhp0lw8ehux6vxweq9ppa Is Manager: false Node Address: 192.168.65.3 Manager Addresses: 192.168.1.30:2377 Runtimes: runc Default Runtime: runc Init Binary: docker-init containerd version: b34a5c8af56e510852c35414db4c1f4fa6172339 runc version: 3e425f80a8c931f88e6d94a8c831b9d5aa481657 init version: fec3683 Security Options: seccomp Profile: default Kernel Version: 4.14.131-linuxkit Operating System: Docker Desktop OSType: linux Architecture: x86_64 CPUs: 2 Total Memory: 1.945GiB Name: docker-desktop ID: I43Z:QQ62:NNEL:KWW7:VROV:73NC:AN6P:H3NR:DQ2P:22LF:XLRG:UN6Z Docker Root Dir: /var/lib/docker Debug Mode: true File Descriptors: 91 Goroutines: 167 System Time: 2019-10-24T20:25:33.594451663Z EventsListeners: 6 Registry: https://index.docker.io/v1/ Labels: Experimental: true Insecure Registries: 127.0.0.0/8 Live Restore Enabled: false Product License: Community Engine


### Steps to reproduce the behavior
  1. install docker desktop edge in linux mode
  2. docker run -it --rm -p 8090:8090 scyto/nodelink:dev-latest
  3. try accessing http://ipaddressofhost:8090 from another machine - works
  4. ctrl-break to kill container
  5.  docker run -it --rm --network host scyto/nodelink:dev-latest
 6. try accessing http://ipaddressofhost:8090 from another machine - does not work
ad-on-is commented 4 years ago

I have exactly the same issue.

docker-robott commented 4 years ago

Issues go stale after 90d of inactivity. Mark the issue as fresh with /remove-lifecycle stale comment. Stale issues will be closed after an additional 30d of inactivity.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle stale

scyto commented 4 years ago

/remove-lifecycle stale

docker-robott commented 4 years ago

Issues go stale after 90 days of inactivity. Mark the issue as fresh with /remove-lifecycle stale comment. Stale issues will be closed after an additional 30 days of inactivity.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle stale

docker-robott commented 4 years ago

Closed issues are locked after 30 days of inactivity. This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle locked