Sure. I wasn’t meaning to suggest GDM would start the agent in the user’s login session. Rather, I was thinking for the specific case of remoting the greeter, where there’s not a standard autostart mechanism, and even if GDM switches using DynamicUser, other login managers might not.
For this case, the GDM wouldn’t need any additional session management functionality to invoke the agent directly. It would just need to provide it to the greeter session, which would be the party responsible for starting it. (This would work because, unlike the user session, the greeter session could be relied upon to be running a GNOME/GDM-greeder session that understands launching the user agent.)
The actual user session could still use any of the several mechanisms contemplated previously.
Obviously, there will always be niche use cases we can’t support, but I’m trying to consider the following main use cases when thinking about a future common API for remote desktop usage:
- GDM + GNOME (our first priority)
- SDDM + KDE Plasma
- LightDM + Xfce (Xfce hasn’t migrated to Wayland yet, but work looks to be in progress and the result seems likely to be wlroots-based.)
While I can’t guarantee that all three of these will choose to implement (or accept implementations of) whatever we come up with, I’d to avoid any decisions that would make it especially onerous for any of them.
Additionally, there are three more use cases that would be nice to support, as long as it doesn’t negatively impact the other three use cases:
- Headless X11 sessions
- Simple sway session with ly on the local console and a separate login manager for remote logins.
- A system running OpenRC
My plan for now is to create a working proof-of-concept with the existing unstable GNOME APIs, and then use the experience to inform a draft proposal for a standard API.
Not touched on at all yet in this discussion is audio, which is needed for accessibility, and needs to avoid accidentally playing to the local speakers when a session is headless or curtained for remote access.
Does GNOME Remote Desktop currently provide any support for audio? If so, how does redirecting the audio work? I believe when I looked into it last (over a year ago, at least), there was a suggestion that one approach would be to have a way to tag a virtual sink as a remote desktop virtual output, and have WirePlumber know to automatically route all sound to it when such a sink is present, but I don’t know if there’s been any progress in that regard.
(A general discussion of audio remoting might make more sense in PipeWire venue, but I’m curious on GNOME’s take.)