3 ms·
Thank you for your reply. Do I understand correctly that the biggest issue is the fact that containers won't run on the same node and you'd thus have storage is
by mosselman 8y ago
Thank you for your reply. Do I understand correctly that the biggest issue is the fact that containers won't run on the same node and you'd thus have storage issues? Would these issues be (partially) mitigated if you'd run postgres on a single node?
- cpuguy83 8y agoIf you can express your storage requirements via the existing mounts api, then yeah it's all possible. The thing to remember is mounts are implemented only at the node level, so there is no cluster-aware storage controller.
- keypusher 8y agoIf you are running multiple copies of postgres on a single node, then you have not significantly improved the resiliency of your database to failure, and it still does not solve the state transition problem. What happens when the primary database fails (or the node dies)? Whether it is on this node or another node, you need to have a replica (sync or async) that you can fail over to, preferably in an automated way. Docker swarm is not equipped to handle these transitions for you, at which point you are just running your database in Docker, with no real benefit over running it on actual hardware or a VM, and with significant added complexity.