-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Consider adding Requisite/Conflict equivalents that do not trigger OnFailure #12352
Copy link
Copy link
Open
Labels
RFE 🎁Request for Enhancement, i.e. a feature requestRequest for Enhancement, i.e. a feature requestpid1
Description
There are two slightly different use cases for this. The commonality in these two cases is the idea of using use OnFailure in GNOME to start the full screen "Session Failed" dialog. i.e. I have a gnome-session-failed.target which should be executed if certain services fail.
However, some of these services should only run when certain other targets are already present or not present. There are two scenarios:
- The service should only run when another target is present (not used yet, but planned). This means it should run for example when both
bluetooth.targetandgnome-session-initialized.targetare up (i.e. both inRequisite/After/PartOf/WantedBy). - The service conflicts with another target. An actual example is not running a specific service in the GDM session, which I right now solve using
Conflicts=gnome-session@gnome-login.target(gnome-loginis the session type).
I believe in both cases the Requisite or Conflicts will cause the unit to go into the failed state, triggering OnFailure. I can easily work around this by having a .target with the dependencies and a separate .service with the OnFailure entry. This works great, but it is a kind of cumbersome (and causes unnecessary logging).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
RFE 🎁Request for Enhancement, i.e. a feature requestRequest for Enhancement, i.e. a feature requestpid1