Is it possible (or inadvisable) to run apache using the /usr/sbin/apache binary directly? Is there any significant production issues that might arise?
On Sun, Oct 25, 2015 at 3:26 PM, David Aronchick <aronch...@gmail.com> wrote: > I appreciate your feedback. I apologize for providing additional context > about my question, I won't do that in the future. > > All I'm looking to do is run Apache in single threaded non-forking mode, > and output all its output to stdio/stderr. I thought that some folks on > this list might have done that before (inside or outside a Docker > container) and wanted to know how to do that. As the language in the > documentation implied that -X would do this (but should NOT be used for > production purposes), but did not explain _why_ it should not be used for > production purposes. > > I had tried -DFOREGROUND before, but had not tried -DNO_DETACH. I'll do > that. > > > On Sat, Oct 24, 2015 at 9:11 PM, Kurtis Rader <kra...@skepticism.us> > wrote: > >> On Sat, Oct 24, 2015 at 3:35 PM, David Aronchick <aronch...@gmail.com> >> wrote: >> >>> I understand it's not a best practice to run Apache in single process >>> mode for most situations, but what about inside a Docker container? >>> >>> My goal is to have the logs & errors output to stdio/stderr, and to have >>> the entire container get killed if the process dies. >>> >> >> You might get a useful answer from this mailing list but I wouldn't bet >> on it. >> >> I'm going to assume that by "single process" you meant "single user". >> Since in the context of UNIX like operating systems there really isn't >> anything like a "single process" mode. There is, however, the concept of >> "single user" mode which typically means (modulo modern concepts like >> SELinux) an OS environment that automatically grants superuser privileges >> over a privileged port (e.g., the "console") and inhibits automatically >> starting daemons such as the Apache HTTP server. >> >> Also, there is nothing about a Docker container that constrains you to >> single user mode as far as I know (but I'll admit I've only read about >> Docker and never used it. >> >> Having said all that I'll point out you're probably asking the wrong >> people. Asking how to have Apache HTTP server log all its output to stdout >> and stderr is certainly an appropriate question for this mailing list. But >> you didn't really ask that question. Similarly you can't reasonably expect >> anyone on this mailing list to know how to configure a Docker container to >> die if the Apache HTTP server dies. Nor how to start an Apache HTTP server >> daemon and have its output written to stdout and stderr in a manner that >> can be collected by whatever software monitors the output of a Docker >> virtual machine. >> >> -- >> Kurtis Rader >> Caretaker of the exceptional canines Junior and Hank >> > >