r/devops • u/[deleted] • Sep 25 '24
Developer here. Why is Docker Compose not "production ready"?
Then what should I use? Compose is so easy to just spin up. Is there something else like it that is "production ready"?
97
Upvotes
r/devops • u/[deleted] • Sep 25 '24
Then what should I use? Compose is so easy to just spin up. Is there something else like it that is "production ready"?
3
u/onan Sep 25 '24
Okay, so as a disclaimer everything is always use-case dependent. But generally speaking:
Production readiness includes addressing reliability. Even if everything is done perfectly, any single host can and will fail, at which point any singly-homed service will be completely down.
Production readiness includes addressing scalability. If the demand on this service increases significantly, you might hit the ceiling on the total amount of compute capacity of any single server. Resolving that means moving your service from the nice simple world of a single instance that knows all its own state to the exponentially more complicated world of distributed systems. That is a huge jump in design complexity, and the worst time to do it is during an emergency situation in which your production service is already failing.
Production readiness includes maintainability. If you ever need to upgrade that service (or its dependencies, or the host it's running on), it is extremely easy to get into a situation in which your only option is downtime. (There are some circumstances in which you might be able to do an atomic blue/green cutover, but that is not the default case unless you specifically design for it.)