On Thu, Jul 14, 2016, 19:07 Kai Hendry <hen...@webconverger.com> wrote:
> I would love to see that 10 lines of shell you claimed, but I think you > might be underestimating the fine work that went into Dokku! > It's not so much underestimating the work in Dokku as much as leveraging what systemd and a tool like haproxy provide for services. Here's what a script would do with no socket activation, assuming you're sending traffic to the services with a tool like haproxy and have an interface like a control socket [1]: 1. Tell haproxy to stop sending traffic to service instance A. 2. systemctl restart instance-a.service 3. Tell haproxy to start sending traffic to service instance A and stop to B. 4. systemctl restart instance-b.service 5. Tell haproxy to start sending traffic to service instance B. Alternatively, you could track state of a flip-flop and stabilize on only one service instance at a time after the restart. [1] https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#9.2
_______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel