App launch stuck in pending

I have been following this guide to deploy an app Getting Started · Fly Docs

Running fly launch seems to finish properly, albeit warning me that I’m not using Phoenix 1.7.9 (Im on 1.7.10).

The database starts up properly. However the app never starts. No machines are created. The app is simply stuck in pending.

I have been trying for days. Destroying app, launching new ones. Waiting over night. I have tried deploying both to Stockholm and London. Same result. Hobby plan.

Any help would be much appreciated. Thanks!

Hi,

That’s strange :thinking:

Do you have a credit card linked to your account? I wonder if (total guess) it’s blocking because there needs to be a means of payment … (under the Hobby Plan, usage under $5 is waived but I believe you still need to provide a card to prove you’re human)

If you do … does running flyctl logs show any error? Normally if there is some fault (wrong port etc) that should show up there, and would cause the app to fail to start. Not sure what else to suggest as you have already tried a different region.

Thanks for responding!

I have a credit card linked and I have now also added 25 dollars in credits to my account and tried another two regions. Still just pending.

Im trying to use the shared-cpu-1x 256MB RAM-machines.

Database machines will spin up, but the actual app is always stuck in pending.

1 Like

Hi,

Weird! It’s not the payment then :thinking:

Hopefully someone from Fly will be able to check for you.

In the meantime all I can suggest is look at the app’s logs with flyctl logs (from the folder your fly.toml is in) and see if it shows any reason why the machine is stuck. Sometimes it is an invalid port (like 8080 vs 3000) if the app is listening on a port that doesn’t match what is in fly.toml. But … I don’t know I’m afraid.

I managed to figure it out.

The guide only told me to run fly launch, however if I only ran that the app was stuck in pending forever. I now tried to run fly deploy after fly launch and now the app is up and running properly.

Did I missread the guide or has flyctl changed somehow? fly version says flyctl.exe v0.1.141 windows/amd64 Commit: e01eaaa3bfce175252caa354bbb2a0f5558d618f BuildDate: 2024-01-11T03:07:27Z.

Thanks for your help.

1 Like

Ah … ok, good you got it working.

I’m not sure if they changed it. As I recall (from a while back) fly launch asks whether to deploy now. It’s an option since there are times when you won’t want to (like if you need to set/stage a secret first). I thought the default was yes … but perhaps it’s no :thinking:

Anyway, yep, from now on you’ll be using fly deploy.

Sorry for the confusing experience; the Elixir getting started doc hasn’t been updated to reflect the the New Launch.

It no longer prompts y/n to “deploy now” like it used to.

fly launch does a few things, like creating the app and config. For some apps, it will also deploy after doing all that. But for some languages, you need to explicitly run fly deploy after fly launch to get the app up the first time (and then anytime you make changes).

We’ll go through the docs and make updates!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.