I use mpd occasionally and start the mpd service only on demand by using its socket. (Explained here)
That works pretty well.
However, when the mpDris2 service is enabled on boot mpd is started on every boot, no matter if mpd is running or not. The reason is that mpDris2 starts it by connecting to its socket.
This can be tested by
Stopping mpDris2 service
Disabling mpd service
Stopping mpd service
Activating mpd socket
Starting mpd socket
(Checking if mpd is still not started)
Starting mpDris2
(Checking mpd service status: It should be activated if the issue is present)
Is it possible to work around this and keep the mpd socket activation intact by checking if mpd service is active when mpDris2 starts before actually connecting to the socket?
I use mpd occasionally and start the mpd service only on demand by using its socket. (Explained here) That works pretty well.
However, when the mpDris2 service is enabled on boot mpd is started on every boot, no matter if mpd is running or not. The reason is that mpDris2 starts it by connecting to its socket. This can be tested by
Is it possible to work around this and keep the mpd socket activation intact by checking if mpd service is active when mpDris2 starts before actually connecting to the socket?
Best regards Tobias