fix(linux): fix systemd service file#4561
fix(linux): fix systemd service file#4561gdesmott wants to merge 2 commits intoLizardByte:masterfrom
Conversation
xdg-desktop-autostart is not active on Fedora with GNOME.
Fix "Error reading events from display: Broken pipe" when starting if the display is not ready yet.
|
|
I think we actually need a way to handle different environments... because this file just keeps getting changed back and forth. |
|
I'm not an expert but as I understand it Is there any setup where |
|
I am not an expert either, but we do need to handle non wayland environments. I found this (https://systemd.io/DESKTOP_ENVIRONMENTS/), maybe it has some answers. |
|
I think xdg-desktop-autostart fits better because it is started by (and thus after) graphical-session. My understanding of the distinction is that graphical-session will cover initialization of low-level services needed to start a graphical session such as Xorg and wayland compositors, whereas xdg-desktop-autostart is focused on apps to be started within the actual graphical session. Sunshine should be treated more like the latter than former because we depend on the graphical session first being initialized in order for capture initialization to work. What distro(s) are not shipping xdg-desktop-autostart? Perhaps the addition of "After=graphical-session.target" might be an acceptable middle-ground if this really is an issue with some distributions (and thus you will have to depend on the 5 second delay in the service file to hope that your graphical session actually finishes loading before sunshine initialization starts), but I agree with @ReenigneArcher that changing the base xdg-desktop-autostart dependency is wrong. |
|
However, on Fedora 43 with GNOME, xdg-desktop-autostart is not started, while on KDE it is. As a result, xdg-desktop-autostart may not be a stable point of reference. |
Yes, I'm using that as well, that's why I changed it to |
This comment was marked as resolved.
This comment was marked as resolved.
|
I think we don't need to map out distros in such detail. The basic issue is that the standard GNOME desktop doesn't use xdg-desktop-autostart.target. Fedora 43 GNOME: I don't have the log handy, but Fedora 43 KDE does start the xdg-desktop-autostart.target by default. Given that 1/2 major DEs don't use this unit file, we shouldn't rely on it - but we can still use it for startup service ordering. My recommendation:
In summary:
|
|
I won't be able to test it for now so @psyke83 feel free take the relevant bits from my PR and open a new one. |



Description
A couple of changes ensuring the service is properly started after
graphical-session.target.Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage