cvkmohan

cvkmohan

Can Supabase be the backend for Phoenix LiveView

Hello, https://supabase.com is a big success in the Javascript world as a Firebase alternative. For whatever reasons, Supabase is completely focused with integrations with JS frameworks.
What caught my attention is the global CDN nature of Supabase hosting. Though, we can do a single click deploy of phoenix applications on https://fly.io, database hosting is still an issue. Though, Fly supports for easy deployment of Postgres, it is not managed hosting. Database backups, recovery etc. are our headache.
Considering all this scenarios, is Supabase a good alternative for database operations in our LiveView application? Ofcourse, Supabase provides even File Storage as well - which Fly does not give.
So, Fly Hosting for Phoenix Application - Supabase for Database and File Storage - can it be a good stack for production apps?
I had this doubt for sometime - but - zoedsoupe/supabase: A complete Toolkit to interact with Supabase APIs from Elixir (github.com) - triggered those thoughts again.
I request you to offer your views- pros and cons.

Most Liked

zoedsoupe

zoedsoupe

that’s a good question tough! i mean, i started supabase-potion because i would like to use the storage and go true services exactly on phoenix/live view.

that said, the library aims to provide a good interface for supabase APIs, so in my opinion, as others already said, you can connect directly to the database on supabase and use ecto!

i’m thinking if it would make sense to provide a postgrest interface, you can also check the discussion in this thread: Would it be possible to implement an Ecto adapter for PostgREST?

but supabase in general fits greatly with phoenix, specially if you want file storage and if you don’t need/don’t want to handle server authentication in your side!

olivermt

olivermt

Doesnt supabase expose a postgres interface you can talk to from the server directly?

adw632

adw632

Yes, the standard Ecto Postgres support should work as Superbase provides a Postgres interface, meaning anything that talks to Postgres can talk to Superbase.

Where Next?

Popular in Discussions Top

matthias_toepp
I’d love to hear what people think about Wisp, the new Gleam web framework started by Gleam’s primary creator Louis Pilfold. Gleam, alon...
New
PragTob
Hello everyone, I know we had quite some threads (read through lots of them) about background job processing but it remains a hotly deba...
New
WildYorkies
It seems that the more I read, the more I find Elixir users speaking about all the ways that Elixir is not good for x, y, and z use cases...
New
AstonJ
If a newbie asked you about Phoenix Contexts, how would you explain the basics to them? Feel free to be as concise or in-depth as you li...
New
mbenatti
Following https://github.com/tbrand/which_is_the_fastest |> https://raw.githubusercontent.com/tbrand/which_is_the_fastest/master/imgs...
New
AstonJ
I’ve just started the Phoenix part of the utterly brilliant online course by @pragdave. On generating the Phoenix app he uses the --no-ec...
New
AstonJ
Please see the new poll here: Which code editor or IDE do you use? (Poll) (2022 Edition) It’s been a while since we first asked this, I...
208 31142 143
New
saif
Hello everyone, Long time lurker first time poster here. I’ve recently begun working on Elixir full-time again! :raised_hands: It’s been...
New
New
100phlecs
Are there any downsides, like perf issues, to putting all functional components in CoreComponents as long as you prefix it with the conte...
New

Other popular topics Top

malloryerik
Hi, this is for people who, like me, have had some friction using .html.heex templates in VSCode. The solution seems to be, in a hyphena...
New
lastday4you
I wanted to check elixir version in phoenix because i found that my elixir is 1.5 but when i use Enum.chunk_by it said the function is un...
New
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New
jononomo
I am trying to figure out how Mix knows whether the environment is test, dev, or prod – where is this set? Thanks.
New
Lily
In templates/appointment/index.html.eex: <%= for appointment <- @appointments do %> <tr> <td><%= appoi...
New
pmjoe
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
alice
Hey, Just curious what are the main benefits of Elixir compared to Clojure? When is Elixir more useful than Clojure and vice versa? Th...
New
belgoros
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
jason.o
In the code below, if the create action is not set to accept “extra_key” as an input, it errors out with a message shown above. Is there ...
New
PeterCarter
There are pre-rolled solutions for other frameworks that do work. However, Phoenix does not seem to have these. Have people had good expe...
New

We're in Beta

About us Mission Statement