Packaging Supabase with Nix

14 Likes

This is awesome. Congrats Sam! Looking forward to the package being available on macOS.

2 Likes

Seems like Nix would have a couple of things to make it compelling here:

  • Dealing with a wide matrix of versions & extension variations. Since packages in Nix can be results of a function, it’s straightforward to vary the versions of each.

  • Managing multiple artifacts: Docker images, native binaries, cloud images (AMIs). You get the benefit of knowing that each of these will work the same way (since they’re running the same programs/libraries)… and although Nix is complex, it’s going to be complex to manage these different artifacts anyway. – If someone wanted an image for GCP, presumably that’d be easy for them to construct, too.

1 Like

Yes totally. And maybe if you have 10+ postgres extensions, and perhaps want to test and validate various pg versions (14, 15, 16, 17 etc) , migrations, etc. Nix just has a great set of tools for dealing with all of that.

2 Likes

Very nice Sam. Thanks for sharing.

1 Like