HOWTO: Install NixOS on an OVH dedicated server

Hi,

I’ve spent the last couple of days trying to get NixOS on my OVH dedicated server, bootstrapping it from the OVH rescue mode.

Goal: To get a proper partitions -> RAID -> LUKS -> LVM -> ext4 setup for the data partition, unencrypted / for booting through, but and RAID for everything, including the EFI System Partition (ESP). (I also tried legacy boot, but that only gave me a black screen.)

You can find the script I wrote for it, including detail instructions and explanations, here:

Thanks to clever on IRC who helped me with much of it.

For my own usage, this is only to bootstrap the server to NixOS; afterwards I’ll manage it with nixops.

1 Like

Perhaps also useful to know: The script takes 3:45 minutes to run on my STOR-1 type server.