Many programs allow to be run either in daemon mode (which is usually the default), or explicitly run it in foreground with a flag such as -f
.
Now when configuring upstart to run programs like this, I can either do
exec foo -f # run in foreground
or
expect fork
exec foo # automatically runs as a daemon
Is there a reason to choose one over the other? It feels that it's just easier to run everything in foreground and let upstart handle the processes, but is there a downside to that?