summary refs log tree commit diff
path: root/nixos/modules/services/desktops
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2018-08-16 17:15:05 +0200
committerGitHub <noreply@github.com>2018-08-16 17:15:05 +0200
commit6f8fe25ccfb138d716d3b1c0cea25e6f11208d45 (patch)
treedf4b2de307ea49d1efe917660da5fae0f4965b83 /nixos/modules/services/desktops
parented2148b5af8b4d4f6f5ecbc4bd72ecabe1c25acc (diff)
parent7fbdd7fcf4242f406182c4b2671f25e1d2c86397 (diff)
downloadnixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar.gz
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar.bz2
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar.lz
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar.xz
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.tar.zst
nixlib-6f8fe25ccfb138d716d3b1c0cea25e6f11208d45.zip
Merge pull request #45107 from mnacamura/lightdm-accountsservice
lightdm: enable the accounts daemon to find dbus interface
Diffstat (limited to 'nixos/modules/services/desktops')
-rw-r--r--nixos/modules/services/desktops/accountsservice.nix10
1 files changed, 8 insertions, 2 deletions
diff --git a/nixos/modules/services/desktops/accountsservice.nix b/nixos/modules/services/desktops/accountsservice.nix
index 2a7450669ea0..933b9da2c83c 100644
--- a/nixos/modules/services/desktops/accountsservice.nix
+++ b/nixos/modules/services/desktops/accountsservice.nix
@@ -32,15 +32,21 @@ with lib;
 
     environment.systemPackages = [ pkgs.accountsservice ];
 
+    # Accounts daemon looks for dbus interfaces in $XDG_DATA_DIRS/accountsservice
+    environment.pathsToLink = [ "/share/accountsservice" ];
+
     services.dbus.packages = [ pkgs.accountsservice ];
 
     systemd.packages = [ pkgs.accountsservice ];
 
-    systemd.services.accounts-daemon= {
+    systemd.services.accounts-daemon = {
 
       wantedBy = [ "graphical.target" ];
 
-    } // (mkIf (!config.users.mutableUsers) {
+      # Accounts daemon looks for dbus interfaces in $XDG_DATA_DIRS/accountsservice
+      environment.XDG_DATA_DIRS = "${config.system.path}/share";
+
+    } // (optionalAttrs (!config.users.mutableUsers) {
       environment.NIXOS_USERS_PURE = "true";
     });
   };