flyctl scale calls SetAppVMSize which calls the setVmSize mutation. This mutation appears to schedule the scale job asynchronously/returns early, but I want to use flyctl to set VM size synchronously - possible?
Background
I'm trying to write a CI GHA that temporarily scales a VM up for a brief-but-resource-hungry job, then scales the VM back down after. I noticed flyctl monitor is blocking and comes close to what I need, however apparently if I don't call it at exactly the right time, it fails which breaks the job.
Not sure best way to arrange, but something like e.g. flyctl scale --wait {...} would be nice.
$ flyctl scale {...}
Scaled VM Type to
dedicated-cpu-4x
CPU Cores: 4
Memory: 32 GB
$ sleep(x) where x is "the correct" amount of time
$ flyctl monitor
Error app seafowl-socrata is not currently deploying a release. The build and release command must succeed before a release is deployed. The latest release version is 51
# uh oh, wrong amount of time
TL, DR
flyctl scale
calls SetAppVMSize which calls the setVmSize mutation. This mutation appears to schedule the scale job asynchronously/returns early, but I want to useflyctl
to set VM size synchronously - possible?Background
I'm trying to write a CI GHA that temporarily scales a VM up for a brief-but-resource-hungry job, then scales the VM back down after. I noticed
flyctl monitor
is blocking and comes close to what I need, however apparently if I don't call it at exactly the right time, it fails which breaks the job.Not sure best way to arrange, but something like e.g.
flyctl scale --wait {...}
would be nice.