Stop using network_mode: host for nginx and haproxy
Using host network reduces separation and potentially exposes more ports publicly than needed or intended. In some cases (such as opening up many dynamic ports) this is needed, but for haproxy and nginx this is not the case. Haproxy only needs port 80 and 443 externally, and nginx normally does not need to expose anything external (only to another reverse proxy such as haproxy).
With some care, these containers can be changed to use regular networking instead (which is what this PR does).
See the commit messages for details.
Issue #138 also talks about a change like this and suggests that it would not be possible. If I read that issue correctly (but it is vague and only implies the issue), it might suggest that it would not work because freeswitch would need ipv6 connections to be forwarded over ipv6, which is what the nginx example in https://github.com/bigbluebutton/docker/blob/develop/docs/existing-web-server.md does. However:
- The apache example on that page forwards everything over ipv4, as does the default haproxy production forwarder
- I've tested the resulting build with a client that connects to the server (haproxy) over ipv6, which then connects to the underlying nginx over ipv4, and that works fine (audio and video connection to another host that might have used ipv4, did not check).
- If really needed, the docker internal network could also be configured for ipv6.
There is also a bit of development config (here and here. I've updated this as far as I understand how it works, but I'm not 100% sure (and have not been able to test this, since I was running on a remote server, not locally).