diff --git a/modules/services/system/dbus.nix b/modules/services/system/dbus.nix index b0c8dc66ae50..6f79865645db 100644 --- a/modules/services/system/dbus.nix +++ b/modules/services/system/dbus.nix @@ -130,6 +130,12 @@ in exec = "${dbus}/bin/dbus-daemon --config-file=${configDir}/system.conf"; + postStart = + '' + # Signal Upstart that it can connect to the system bus. + kill -HUP 1 || true + ''; + postStop = '' # !!! Hack: doesn't belong here. diff --git a/modules/system/upstart/upstart.nix b/modules/system/upstart/upstart.nix index 9edb0153cb27..3d2af1b0382f 100644 --- a/modules/system/upstart/upstart.nix +++ b/modules/system/upstart/upstart.nix @@ -311,6 +311,10 @@ in target = "init/${job.name}.conf"; } ); + # Upstart can listen on the system bus, allowing normal users to + # do status queries. + services.dbus.packages = [ upstart ]; + # !!! fix this /* tests.upstartJobs = { recurseForDerivations = true; } //