mozilla-services / Dockerflow

Cloud Services Dockerflow specification
Apache License 2.0
195 stars 28 forks source link

Recommend running one process #46

Closed sciurus closed 6 years ago

sciurus commented 6 years ago

I think there's a number of reasons to run only one process. It lets us more reliably detect whether a container is still running everything we need it to, it lets us generate a coherent stream of logs, etc.

I'm unsure whether to explicitly mention that it's okay to run a single master process that manages its own worker processes (e.g. uwsgi). Another way to accomplish that might be to say "program" rather than "process".

ckolos commented 6 years ago

Can we clarify to say that while containers should only run one process at at time, they are able to do more than one thing depending on invocation?

jbuck commented 6 years ago

Yeah, maybe it's more "Each instance of a container should only run one process. If you need to run two processes, just create another instance of the container & run a different command"

sciurus commented 6 years ago

I like your wording jbuck, so I've swapped it in.

jbuck commented 6 years ago

Approving my own wording, yeah!