Prevent dbus-reload hook from throwing an error when dbus isn't running
This commit is contained in:
@@ -2,4 +2,4 @@ trigger_operations: ["install", "upgrade", "remove"]
|
||||
target_type: "path"
|
||||
targets: ["etc/dbus-1/system.d/*.conf", "usr/share/dbus-1/system.d/*.conf", "usr/share/dbus-1/system-services/*.service"]
|
||||
depends: ["dbus"]
|
||||
run: "dbus-send --print-reply --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig"
|
||||
run: "/usr/sbin/dbus-reload"
|
||||
|
||||
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
|
||||
echo "Warning: this script should only be run by the dbus-reload BPM hook. Users should avoid running this script"
|
||||
|
||||
# Reload system bus configuration
|
||||
dbus-send --print-reply --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig &> /dev/null
|
||||
|
||||
exit 0
|
||||
Reference in New Issue
Block a user