docker container is not accessible from other machines on host’s network

I was doing some devops and writing a script to turn my current host/nginx server/nginx setup into a host/docker/nginx server/docker/nginx set up so I can keep directories and etc the same between them.

The problem is that any ports I expose on a docker container are only accessible on the host and not from any other machines on the host network.

When typing from a machine such as it just says took too long to respond, but typing from will bring up the welcome to nginx page?! The interesting part is I did a wireshark analysis on en0 on port 80 and there are actually some ports coming through

See pastebins of packet inspections:
LAN to docker:
Host to docker:

I’ve tried using docker run -p nginx/nginx and docker run -p nginx/nginx but this doesn’t seem to fix anything.

Should see welcome to nginx when connecting from to

this is in my dev environment which is an osx 10.13.5 system.

when I push this to my ubuntu 16.04 server it works just fine with the containerized nginx accessible from the www

Source: StackOverflow