NATS cluster per-region rolling deploy?

Hello! I have worked through a couple issues to allow a NATS Jetstream cluster to handle restarts more gracefully. One thing stands out: a deploy for a super cluster will take down a whole independent region. I have 9 across three regions. The deploy took down 5 to deploy.

Is there any way to deploy one at a time?

I am not sure if this is related: Can't set --max-per-region value
While the deploy correctly deploys 3 per region, the CLI doesn’t show the max per region value still.

Here: Rolling restart - #9 by ryansch is a work around to enable a rolling restart.

I don’t have a way to destroy a single VM though. Is there something possible through the GraphQL API perhaps?

fly deploy --strategy rolling_one might work.

In general, though, you’re better off using Machines and something like Terraform than the fly deploy command. It’s a bit hard to control what happens with the Nomad based apps, Machines can be managed one by one.

1 Like