Fix sleep lock session environment race (#6493)

Found by @tobi.
This commit is contained in:
David Heinemeier Hansson
2026-08-01 15:38:55 -05:00
committed by GitHub
parent 0af39c5260
commit 2cff67fa45
5 changed files with 260 additions and 1 deletions
@@ -1,7 +1,13 @@
[Unit]
Description=Lock Omarchy before suspend
After=dbus.socket
# The monitor calls into the running Omarchy shell. Wait until UWSM has imported
# OMARCHY_PATH and WAYLAND_DISPLAY, but keep the default target ordering so the
# monitor starts before graphical-session.target is reached.
After=dbus.socket wayland-session-waitenv.service
Requires=dbus.socket
PartOf=graphical-session.target
ConditionEnvironment=OMARCHY_PATH
ConditionEnvironment=WAYLAND_DISPLAY
[Service]
Type=simple