Hi, I have a problem starting a systemd user service upon login with GNOME 40.
I used to do it easily in GNOME 3.3x with:
[Unit] PartOf=graphical-session.target After=graphical-session.target ... [Install] WantedBy=graphical-session.target
I need to run such services only after the graphical session and not with
default.target, because these programs may have some constraints like being a graphical program (thus needing an X display to start) or needing SSH access to a machine (thus needing my SSH passphrase unlocked by GNOME keyring), etc.
But, this doesn’t work anymore with GNOME 40.
I also tried with other settings (
gnome-session.target instead of
BindsTo=, etc etc ) but it didn’t work either.
It seems there was a big change in the session management in GNOME 40, because when I list user services with
systemd --user status, I only see a bunch of services and the apps I started manually during the session, but not the usual GNOME services (like the various settings daemon modules for example) nor the apps started automatically from XDG autostart desktop files; all those are now in another CGroup (
session-X.scope) instead of the usual
So, what is the new correct way to start a systemd user service with GNOME 40 ?