I have installed NixOS, and I love it. I configured everything, I tested everything, and I wanted to add Nvidia drivers. I followed instructions and I added these two lines to my config:
services.xserver.videoDrivers = [ “nvidia” ];
hardware.nvidia.modesetting.enable = true;
I also checked with lsmod and lspci and the kernel module and the GPU is detected. However when I boot up my system I see no X output. It stalls at “Starting target Graphical User Interface”. Another weird thing, as I tried to troubleshoot by going to console mode, I ran nvidia-smi as normal user and I got “No devices detected”. When I run it as root it works. I also checked that the nouveau driver is blacklisted. I am a bit confused on how to fix this. I am new to NixOS, sorry if this is a stupid question.