Couldn't find provided session name

Hi, I just installed NixOS. I followed the installation manual, rebooted, loged in to a tty as a root to add password to my normal user and change the display manager to gdm like so:

services.xserver.displayManager.gdm.enable = true;
services.xserver.displayManager.sessionPackages = [ pkgs.gnome.gnome-session ]; # I do not use the normal Gnome package, I made my own minimal install which I used on Arch, and copied this from a reddit post

Relogged as my normal user, and ran nixos-rebuild boot, but I got this error:

Couldn't find provided session name, gnome.desktop, in session package gnome-session-40.1.1

You want

services.xserver.displayManager.sessionPackages = [ pkgs.gnome.gnome-session.sessions ];

I would look at nixpkgs/gnome.nix at acae534d06565ee054916bfb3c747a188ba1f203 · NixOS/nixpkgs · GitHub for any other gnome assumptions which might be missing.

Oh, I looked over that in the reddit post :sweat_smile:. But I got inpatient anyway and just installed Gnome and disabled the apps with services.gnome.core-utilities.enabled = false, it has pretty much the same effect…

1 Like

I went to try it anyway and got this instead…

error: attribute 'session' missing, at /etc/nixos/configuration.nix:107:5

missing an s. sessions

2 Likes