What is `fly console` session timeout?

Hi, I am getting the error wait: remote command exited without exit status when keeping a fly console session for too long.

Is this error related to ssh, Fly or something else?

Is there a config option to increase this timeout if this is related to fly console?

Is there a way to exit from the fly console session without killing the running process?

Hi… If you don’t need the interactive session at all, then you might like fly m run --rm for this.

For example…

$ time fly m run --rm --name ephemeral -a app-name debian:bullseye-slim -- sleep 60
real 0m7.000s
user 0m0.200s
sys  0m0.035s
$ fly m list
ID              NAME       STATE    REGION
abcdef99543210  ephemeral  started  ord

(Still running!)

Hope this helps a little!


Aside: The double-hyphen before sleep isn’t strictly necessary here, but it’s a good reflex for the general case—when the command takes its own flags.

1 Like

Awesome thank you! Does the machine inherit the app secrets? It would be awesome if you could add that, in my case for example I would have to hard code the secrets as —env in the command, which decreases security instead of increasing it

Yep, it should get the secrets of the app named in the -a flag.

(I just double-checked that and it did work.)

1 Like