Hi,
I wanted to use nix / nixos and I couldn't find any info in this thread.
So here's my steps for what I did to get nixos working. It's based on the wiki here https://nixos.wiki/wiki/Proxmox_Linux_Container
These steps could be stream lined for someone else, but this is what I did. If you have any suggestions on how I can improve this procedure, please let me know.
1. Download the container tarball from hydra as described on the nix wiki and save it to your unraid server.
2. Setup a new lxc container, such as ubuntu jammy. I mostly did this to get the config file. I named my container NixOS
3. cd to the NixOS folder from the unraid terminal.
4. Delete the contents of NixOS/rootfs folder (i.e. rm -rf NixOS/rootfs/*) .
5. Extract the hydra container tarball to NixOS/rootfs
6. `mkdir NixOS/rootfs/.ssh`
7. echo "your ssh public key" > NixOS/rootfs/.ssh/authoriized_keys
8. chown 0600 NixOS/rootfs/.ssh/authoriized_keys
9. Edit the config file and add this line:
lxc.init.cmd = /sbin/init
10. (Optional) copy the NixOS folder to NixOS-template so that you can reuse it later. Then, you can just create copies of it
11. Start the NixOS container.
Done.
12. (Optional) if you want to create a new container from your template, just copy it the NixOS-Template to it's new name, like NixOS-App. Then, edit the network address of NixOS-App/config and give it new address and modify the path of the rootfs.