Configuring a NixOS tilde/pubnix - managing user configuration

Hi all,

I’m a NixOS noob- I have played around with nix-portable, containers/VMs, etc.

To learn NixOS, I’m considering hosting a tilde/pubnix running NixOS. (A tilde/pubnix is a host that gives out UNIX accounts to other people.) I think NixOS is a great match because a) I can publish configuration.nix and allow users to collaborate b) has a large selection of software c) I’m not aware of any NixOS tilde/pubnix.

My question is: as a NixOS user, what would be your preferred way for the system to deal with your user environment? Would there be a nice way for users to provide, say, a Git URL to a home manager configuration, and have configuration.nix deploy and keep updated their setup?

Secondarily; I’m using Incus for developing the pubnix/tilde configuration, and I have a script to quickly create an LXD container or VM with a given configuration. What would be a good way to manage multiple environments with slightly different configuration? (E.g. the main public server, test instances for me or users, etc. It would also be cool to allow others to run their own pubnixes/tildes based on my configuration.)