Suspended machines are stopped on new deploy

The autoscaling has been working great for me, but I’ve noticed that anytime I deploy, the suspended machines get updated and then stopped. I would expect the machines to get back in their suspended state so they can boot up again quickly when needed.

I understand this might be expected behaviour, but is there anything I could do to get them back in suspended state aside from starting them manually and waiting for them to go in that suspended start?

toml:

[[services]]
  internal_port = 5001
  force_https = true
  auto_stop_machines = "suspend"
  auto_start_machines = true
  min_machines_running = 1
  processes = ['app']
1 Like

Here’s what I got from support when I asked:

This would appear to be related to some temporary capacity issues in IAD, over the last week. When your app scales to zero with an auto_stop_machines setting, if there’s a lack of host capacity in the region we’re sometimes not able to bring up the Machine when the Proxy auto-starts it.

In this case, I’d recommend ether of two things:

  1. set auto_stop_machines = "off" in your fly.toml
  2. scale your app to a nearby region with fly scale count

Basically, it seems like if they can’t start it right away, they give up on trying to start it all together. Hopefully that’s not the same behavior with their k8s API, and that they fix this going forward.