4 ms·
Tech Stack Backend: Elixir & Phoenix Database: PostgreSQL with Supabase (originally CockroachDB, big mistake) Auth: Supabase Frontend: Next.js
by vasanthk1125 2y ago
Tech Stack
Backend: Elixir & Phoenix
Database: PostgreSQL with Supabase (originally CockroachDB, big mistake)
Auth: Supabase
Frontend: Next.js
UI Components: shadcn
GraphQL API: Absinthe
Hosting: Fly.io (Phoenix) + Vercel (Next.js)
Storage: Cloudflare R2 + CDN
- cyberpunk 2y agoWhat happened with cockroach? :)
- osm3000 2y agoI am curious too
- _huayra_ 2y agoThey switched to a non-free license about 6 months ago [0]. This is not just the usual BSL terms of "do not compete with our hosted offering, but use it in your own product without issue", but they mandate telemetry from the free version. Oxide and Friends did a great episode on it at the time [1]. [0] https://www.cockroachlabs.com/docs/stable/licensing-faqs https://www.cockroachlabs.com/docs/stable/licensing-faqs [1] https://oxide-and-friends.transistor.fm/episodes/whither-cockroachdb https://oxide-and-friends.transistor.fm/episodes/whither-coc...
- BozeWolf 2y agoWhy do you use supabase and not just postgres? Do you use supabase’s api interface to do the queries? Or do you use supabase for other features?
- vasanthk1125 2y agoWhen I first started working on the website nine months ago, I didn’t even know what Postgres was, so going with an easier option made sense. Right now, we also use Supabase for auth and emails. For queries, we don’t use Supabase’s API interface—we interact with Postgres directly through our backend
- BozeWolf 2y agoThanks for your answer. Interesting take that you did not know about postgres, but chose an api for storage instead. I would have done the opposite.
- SpaghettiCthulu 2y agoWell, they use Supabase for auth. Perhaps there's other integration there.
- julienmarie 2y agoWhy Next.js and not Liveview? Little note: It seems the search is only by book title, not by author and not resilient to typos.
- vasanthk1125 2y agoLiveView just has fewer libraries. For example, we use a rich-text editor called TipTap, and I’m not sure there’s anything similar for LV. Yeah, search is currently by book title and series name. It should handle typos pretty well—Meilisearch allows for up to two—but I still need to tweak it further
- mmanfrin 2y agoDoes Phoenix have auth? Any reason you chose supa over phoenix? And do you store user info (reviews+stuff) in phoenix and just reference it with the supa uuids or do you store user generated info on their own in supa?
- vasanthk1125 2y agoPhoenix doesn’t have built-in auth, and setting it up with Guardian (the JWT library for Elixir) took too much time. Since we were already using Supabase for Postgres, we decided to go with its auth to move faster. Supabase provides a UUID after authentication, which we then use throughout the rest of the database.
- saltcod 2y agoWhy Elixir & Phoenix and Next.js?