nixos/pantheon: Add missing gala-daemon systemd services

Otherwise it doesn't autostart after user session managed by systemd.
This commit is contained in:
Bobby Rong 2024-01-27 16:20:15 +08:00
parent e49a58b847
commit a4bca9aaef
No known key found for this signature in database
2 changed files with 19 additions and 0 deletions

View File

@ -190,6 +190,22 @@ in
"org.gnome.SettingsDaemon.XSettings.service"
];
# https://github.com/elementary/gala/issues/1826#issuecomment-1890461298
systemd.user.services."io.elementary.gala.daemon@" = {
unitConfig = {
Description = "Gala Daemon";
BindsTo = "io.elementary.gala@.service";
After = "io.elementary.gala@.service";
};
serviceConfig = {
Type = "dbus";
BusName = "org.pantheon.gala.daemon";
ExecStart = "${pkgs.pantheon.gala}/bin/gala-daemon";
Slice = "session.slice";
};
};
# Global environment
environment.systemPackages = (with pkgs.pantheon; [
elementary-session-settings

View File

@ -70,6 +70,9 @@ stdenv.mkDerivation rec {
postPatch = ''
chmod +x build-aux/meson/post_install.py
patchShebangs build-aux/meson/post_install.py
# https://github.com/elementary/gala/issues/1826#issuecomment-1890461298
sed '2i Wants=io.elementary.gala.daemon@.service' -i 'data/gala@x11.service.in'
'';
passthru = {