It looks like the IP binding is hardcoded in the shell, that it will always use 127.0.0.1 for serving the remote debugging interface. That is nice, considering that the interface do not have any authentication control and it would be best to leave it contained.
However, I have also tried to use docker to build a container for that. It turns out that, by listening 127.0.0.1, docker would not accept localhost traffic to talk to the container. The alternative is to use `-host=net`, which expose the whole network stack in the container to the localhost, but I find that less desirable.
Currently, I use a code patch to replace 127.0.0.1 in the source code with 0.0.0.0 to build the container. I have it uploaded to docker registry in
hub.docker.com/r/yukinying/chrome-headless/, please feel free to take a look if that would help.
And is it possible to provide an optional switch, such that the address binding would be relaxed? It will be extremely useful for people to build container with it.
Thank you!