waybar: fix systemd service

The current definition makes waybar wait for dbus.service, but that
never happens because dbus.service is started on demand by
dbus.socket.

Per systemd docs:
  https://www.freedesktop.org/software/systemd/man/systemd.service.html#Implicit%20Dependencies

- Services with Type=dbus set automatically acquire dependencies of
  type Requires= and After= on dbus.socket.

- Socket activated services are automatically ordered after their
  activating .socket units via an automatic After= dependency.
  Services also pull in all .socket units listed in Sockets= via
  automatic Wants= and After= dependencies.

Removing Requisite/After makes the service properly start for me,
simply specifying Type=dbus is enough.

See #1370
This commit is contained in:
Blaž Hrastnik 2020-11-28 13:06:21 +09:00 committed by Robert Helgesson
parent 0027b0e76b
commit 0654364426
No known key found for this signature in database
GPG key ID: 36BDAA14C2797E89
2 changed files with 0 additions and 4 deletions

View file

@ -356,8 +356,6 @@ in {
"Highly customizable Wayland bar for Sway and Wlroots based compositors.";
Documentation = "https://github.com/Alexays/Waybar/wiki";
PartOf = [ "graphical-session.target" ];
Requisite = [ "dbus.service" ];
After = [ "dbus.service" ];
};
Service = {

View file

@ -9,8 +9,6 @@ RestartSec=1sec
Type=dbus
[Unit]
After=dbus.service
Description=Highly customizable Wayland bar for Sway and Wlroots based compositors.
Documentation=https://github.com/Alexays/Waybar/wiki
PartOf=graphical-session.target
Requisite=dbus.service