* [PATCH BlueZ] mpris-proxy: Stop and start together with dbus.service
@ 2026-11-03 15:17 Mitar
2026-11-03 16:35 ` [BlueZ] " bluez.test.bot
0 siblings, 1 reply; 2+ messages in thread
From: Mitar @ 2026-11-03 15:17 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Mitar
GNOME stops dbus.service when a session ends, with
gnome-session-restart-dbus.service, and the bus is started again through
dbus.socket once a client connects to it. mpris-proxy is not stopped
with the bus: libdbus ends it with exit status 1 when the bus closes its
connection, so the unit fails, and nothing starts it again as long as
the user's service manager keeps running, for example when the user logs
in again within logind's UserStopDelaySec=. The media players of the
next session are then not registered with BlueZ.
Make the unit part of dbus.service, so that stopping the bus stops
mpris-proxy first, and have dbus.service want it, so that it is started
again together with the bus.
---
tools/mpris-proxy.service.in | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/mpris-proxy.service.in b/tools/mpris-proxy.service.in
index 6ae56c6..2b8a4d5 100644
--- a/tools/mpris-proxy.service.in
+++ b/tools/mpris-proxy.service.in
@@ -4,6 +4,7 @@ Documentation=man:mpris-proxy(1)
Wants=dbus.socket
After=dbus.socket dbus.service
+PartOf=dbus.service
ConditionUser=!@system
[Service]
@@ -11,4 +12,4 @@ Type=simple
ExecStart=@PKGBINDIR@/mpris-proxy
[Install]
-WantedBy=default.target
+WantedBy=default.target dbus.service
--
2.53.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-03 16:35 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-03 15:17 [PATCH BlueZ] mpris-proxy: Stop and start together with dbus.service Mitar
2026-11-03 16:35 ` [BlueZ] " bluez.test.bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox