I have a guide for elixir Getting Started with Elixir Phoenix on Fly
Tips and Tricks
Deploying to Staging and Production
It is not so obvious how to use fly.toml
for deployments to both staging and prod. I spent some time searching the docs and finally found this in a doc on monorepos in the examples section,
Use a different fly.toml file per environment
flyctl deploy --config ./fly.production.toml flyctl deploy --config ./fly.staging.toml
This is the closest I've gotten to a definitive answer as to how to deploy to multiple envs. I'm going to use fly.toml
for staging and fly.prod.toml
for prod since I want staging to be the "default" deployment.