I host a web backend on Fly, and currently use a GHA job to perform nightly data ingests.
Because only the ingest job is RAM/resource hungry but “normal” traffic is not, it’s nice to bump resources with
flyctl scale during the ingest only, then scale back down afterwards.
The problem seems to be,
flyctl scale works in an async manner, such that immediately subsequently calling
flyctl monitor won’t work - it must be at precisely the right time. If I call
flyctl monitor too soon or too late, it fails.
Goal is to find a more reliable solution, something other then
sleep to avoid timing risk with chaining these commands.
What might be some alternative ways to scale a Fly VM (including raw HTTP calls if needed) I should consider?