git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #45107 from mnacamura/lightdm-accountsservice

lightdm: enable the accounts daemon to find dbus interface

commit6f8fe25ccfb138d716d3b1c0cea25e6f11208d45 authorJan Tojnar <jtojnar@gmail.com> dateThu 16 Aug 2018, 17:15 (8 years ago) parented2148b7fbdd7f
2 files changed+13−4
nixos/modules/services/desktops/accountsservice.nix+8−2 nixos/modules/services/x11/display-managers/lightdm.nix+5−2
nixos/modules/services/desktops/accountsservice.nix+8−2
@@ -32,15 +32,21 @@ with lib;
3232
3333 environment.systemPackages = [ pkgs.accountsservice ];
3434
35+ # Accounts daemon looks for dbus interfaces in $XDG_DATA_DIRS/accountsservice
36+ environment.pathsToLink = [ "/share/accountsservice" ];
37+
3538 services.dbus.packages = [ pkgs.accountsservice ];
3639
3740 systemd.packages = [ pkgs.accountsservice ];
3841
39− systemd.services.accounts-daemon= {
42+ systemd.services.accounts-daemon = {
4043
4144 wantedBy = [ "graphical.target" ];
4245
43− } // (mkIf (!config.users.mutableUsers) {
46+ # Accounts daemon looks for dbus interfaces in $XDG_DATA_DIRS/accountsservice
47+ environment.XDG_DATA_DIRS = "${config.system.path}/share";
48+
49+ } // (optionalAttrs (!config.users.mutableUsers) {
4450 environment.NIXOS_USERS_PURE = "true";
4551 });
4652 };
nixos/modules/services/x11/display-managers/lightdm.nix+5−2
@@ -15,7 +15,7 @@ let
1515
1616 inherit (pkgs) lightdm writeScript writeText;
1717
18− # lightdm runs with clearenv(), but we need a few things in the enviornment for X to startup
18+ # lightdm runs with clearenv(), but we need a few things in the environment for X to startup
1919 xserverWrapper = writeScript "xserver-wrapper"
2020 ''
2121 #! ${pkgs.bash}/bin/bash
@@ -209,9 +209,12 @@ in
209209 services.dbus.enable = true;
210210 services.dbus.packages = [ lightdm ];
211211
212− # lightdm uses the accounts daemon to rember language/window-manager per user
212+ # lightdm uses the accounts daemon to remember language/window-manager per user
213213 services.accounts-daemon.enable = true;
214214
215+ # Enable the accounts daemon to find lightdm's dbus interface
216+ environment.systemPackages = [ lightdm ];
217+
215218 security.pam.services.lightdm = {
216219 allowNullPassword = true;
217220 startSession = true;