Recommendations for packaging a Rails app as a Nix service

I’ve been using NixOS for a little while now, but haven’t gone deep yet. My exposure to Nix as a language is purely from configuring my own system.

I now have a fairly simple Rails application I want to package and run as a Nix service. I’m currently reading through some documentation on the Nix language, but would appreciate any more specific pointers on good resources to get this done.

Thanks!

The ruby section from the nixpkgs manual might help: Nixpkgs 23.05 manual | Nix & NixOS

And for defining a service you’ll want to read the NixOS manual: NixOS 23.05 manual | Nix & NixOS

Word of warning, both those manuals are just big fuck-off HTML pages, you may need to reload the page after the first load to get the anchor to work because anchor jumps will sometimes occur before the full page loads. They really need to move to docbook or such…

https://nix.dev/ is nice too, but still falls a bit short on NixOS-related topics like this one.

That’s very helpful, thanks :slight_smile: