summaryrefslogtreecommitdiffstats
path: root/data/gnome-session-shutdown.target
blob: 607dc6e71a322010c66e35e799d39ecad144d1a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
[Unit]
Description=Shutdown running GNOME Session

# Allow exit.target to start even if this unit is started with replace-irreversibly
# The same is needed for all (weak) dependencies
DefaultDependencies=no

Conflicts=graphical-session.target graphical-session-pre.target
After=graphical-session.target graphical-session-pre.target

# Add explicit conflicts/after lines for gnome-session targets, technically
# this should not be needed, but is an extra safety measure.
Conflicts=gnome-session.target gnome-session-manager.target
After=gnome-session.target gnome-session-manager.target

Conflicts=gnome-session-pre.target gnome-session-initialized.target gnome-session-failed.target
After=gnome-session-pre.target gnome-session-initialized.target gnome-session-failed.target

# We need to make sure this unit is stopped; primarily so that the tree of
# units that we created is completely cleaned.
# Note that this can also be improved by reversing the conflicts above and
# not listing them in the shutdown unit.
StopWhenUnneeded=true

# We trigger a restart of DBus after reaching the shutdown target this
# is a workaround so that DBus services that do not connect to the
# display server are shut down after log-out.
# This should be removed when the relevant services add a
# PartOf=graphical-session.target
# Historic bug: https://bugzilla.gnome.org/show_bug.cgi?id=764029
Wants=gnome-session-restart-dbus.service
Before=gnome-session-restart-dbus.service