Deploying my first Phoenix app to Fly.io… what do I really need?

Hi,

I’ve been learning Elixir and Phoenix for some time now I would like to deploy my first app to Fly.io. The thing is, I’m a beginner and I don’t really know how to structure my app and volumes.

So, I have a Phoenix app which uses Postgres as a database and the app allows users to upload images. I believe I have to create a VM and then I need to create a volume on which user uploads will be stored, right? Also, as I’m using postgres, do I need to create another volume for it or is there some other way to handle database?

Second, I would like to connect my app to Cloudflare so static files and user images could be loaded from it, how do I set that up?

As I said, I’m a beginner and I really hope someone could give me some guidance on how to set it up properly.

Thanks