Closed tevjef closed 7 years ago
Hey thanks for the contribution! Although, I do believe that exposing the port in the Dockerfile still requires you to bind the port to something on the host, so it would still be required to run with -p.
Ref: https://www.ctl.io/developers/blog/post/docker-networking-rules/
To clarify, this PR would remove the need to use the --expose flag in reverse proxy configurations. If you are proxying connections through a reverse proxy like nginx or haproxy on the same network as your ghost container, you don't need to explicitly publish the port with -p
.
For documentation and correctness, it's a good idea to expose the port your container will be mainly communicating over, especially since the port is hardcoded in the config.js
. As it stands, the -P
does not work as intended. And containers that utilize some automatic service discovery (proxies, load balancers etc.) have no idea how to communicate with alpine-ghost
without an explicit --expose
This change will not break containers downstream.
Re-tagged and built on dockerhub as v0.11.0. Thanks!
Exposing the port in the Dockerfile removes the explicit need to use the
-p
or--expose
flag when usingdocker run
.