Hi, Yep. I have the exact same [email protected] and it works.
BTW, sleep.target is pulled in by both suspend.target and hibernate.target. There are some use cases that a hook should be only invoked by suspend.target (or hibernate.target). For instance, I have a hook used with the tuxoniceui: ---------------------------------------------------- [Unit] Description=tuxoniceui hibernate hook Before=hibernate.target StopWhenUnneeded=yes [Service] Type=oneshot RemainAfterExit=yes ExecStartPre=/bin/bash -c "echo `fgconsole` > %t/tuxoniceui" ExecStart=/bin/chvt 63 ExecStop=-/bin/bash -c "chvt `< %t/tuxoniceui`" ExecStopPost=-/bin/rm -rf %t/tuxoniceui [Install] WantedBy=hibernate.target ---------------------------------------------------- Obviously I don't want it to be called for suspend.target. The problem is, by default, suspend.target/hibernate.target is not a StopWhenUnneeded service. I have to overwrite it in /etc/systemd/system/hibernate.target.d. It's completely OK for me to do this. What I wonder is, what is the reason by they are not StopWhenUnneeded services? Uh, seems overly off-topic... Regards. _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
