diff --git a/infra/nixos/configuration.nix b/infra/nixos/configuration.nix index 1bf239a..703b9f7 100644 --- a/infra/nixos/configuration.nix +++ b/infra/nixos/configuration.nix @@ -64,6 +64,14 @@ }; services.dbus.enable = true; + # The compositor runs as a user service, outside the tty1 login session, + # so logind does not hand it the seat's devices; seatd does, to members of + # its group. + services.seatd = { + enable = true; + group = "seat"; + }; + services.udev.packages = [ pkgs.libinput ]; environment.systemPackages = with pkgs; [ @@ -111,6 +119,7 @@ # units after it; a restarted compositor must not inherit it, or an # X11 DISPLAY, or it would pick the nested backend. UnsetEnvironment = "WAYLAND_DISPLAY DISPLAY"; + Environment = "LIBSEAT_BACKEND=seatd"; Restart = "on-failure"; RestartSec = "1"; }; diff --git a/infra/nixos/weft-packages.nix b/infra/nixos/weft-packages.nix index a5cf849..9d97d2a 100644 --- a/infra/nixos/weft-packages.nix +++ b/infra/nixos/weft-packages.nix @@ -6,13 +6,17 @@ let rustc = rust193; }; - # The workspace without build outputs, so a local `target/` never enters - # the store. - src = lib.cleanSourceWith { - src = lib.cleanSource ../..; - filter = path: _type: - let rel = lib.removePrefix (toString ../.. + "/") (toString path); - in !(lib.hasPrefix "target" rel || lib.hasSuffix "-result" rel); + # Only what the build reads, so editing the VM's configuration or the + # docs does not rebuild Servo. + src = lib.fileset.toSource { + root = ../..; + fileset = lib.fileset.unions [ + ../../Cargo.toml + ../../Cargo.lock + ../../crates + ../../protocol + ../../infra/shell + ]; }; servoHash = "sha256-L5XlHf5GOoPtyitRsbb+keXSkTMSJWmYCrWCHzGFI5M=";