Hi folks! I’ve heard nothing but good things about Fly and wanted to give it a spin. I encountered a few issues following this tutorial and wanted to report them.
-
The base image in the Dockerfile didn’t exist on Docker Hub. Running
mix phx.new hello_elixir
created an application template, and it included a Dockerfile since I was running on Phoenix v1.6.11. This Dockerfile depended on the imagehexpm/elixir:1.14.0-erlang-25.0.4-debian-bullseye-20210902-slim
, which did not exist on Docker Hub, and was causing errors on my build process. I changed it tohexpm/elixir:1.14.0-erlang-25.0.4-debian-bullseye-20220801-slim
, which did exist and works. -
I had to run
fly doctor
twice, out of the box. Something about my local setup prevented me from connecting to Wireguard? I’m not 100% sure I understand how WG is used in the Fly build process, but I was getting weird errors with builds and I guess I needed to ensure WG could get thru the firewall. -
I got stuck with some error about my
DATABASE_URL
being unset. I tried this multiple times, but it didn’t ever work. While deploying my app, Fly is supposed to automatically configureDATABASE_URL
after it spins up a Postgres database in the above tutorial. This never worked. I tried several times (even between deleting and recreating the app with the same and different names.) The failure modes varied wildly:- The app wouldn’t appear at all in the Fly dashboard
- The app would appear, but wouldn’t have any secrets associated
- The app would appear, a secret was present (I manually associated one once) and it still crashed with an error in the logs about no database URL being present.
I’m running macOS 12.3.1 on an M1 chip, Elixir and flyctl were both installed from brew. My most recent test was an app with the autogenerated name of little-bush-7241
, which I’ve since deleted.
I’m not sure how much help I’ll be able to be for troubleshooting, but I wanted to report this since it was a really frustrating experience.