I advise doing everything you can as a limited user, to contain any mistakes you make to things owned by that user. This limits your ability to, for example, remove the filesystem, which would make you computer not-bootable (I understand it’s a VPS, so perhaps it’s more illustrative to talk about getting support involved, or logging into the customer portal).
Based on the fact that you reinstalled, I’d say that the first thing you do is make a user account. Then login to that account and follow the instructions in the nix manual to install nix. After that, confirm that you can run
nix-shell form that account. Then, with the account, clone the repo you’re trying to build. After that, run
nix-shell, also from the same account.
What I’m trying to achieve, is setting up everything as a limited user account and to work in a way that’s many of us are more familiar with, that is to do everything with the user account. This will help with damage control, as I mentioned above, and maybe more importantly, it will make it much easier to follow most documentation, as it’s written from the perspective of a limited user account.
Fell free to call the user account whatever you like (except for root, that probably won’t work). I use “jimmy”, for example.