Open ambis opened 4 years ago
Thanks for your suggestion and your demonstration. We used to use ENTRYPOINT
, but then a user suggested using CMD
. See #51 and #52.
It seems like it could go both ways. I eventually sided with CMD
, mostly because that is how the Nginx images work.
I note that your suggestion (versus the old implementation) combines CMD
and ENTRYPOINT
. This is usually done when the image is intended to always use the same ENTRYPOINT
. But, some users invoke other binaries from this image, e.g. resty
and luajit
.
Now there is
CMD ["/usr/local/openresty/bin/openresty", "-g", "daemon off;"]
, but it could beAnd if I want to override the -g argument, I could do just
Without having to be concerned where the openresty binary resides.
How to verify functionality
Dockerfile
Build it
Run it
Exec into and see process with top