On Di, 28.07.20 15:50, Ulrich Windl (Ulrich.Windl@xxxxxxxxxxxxxxxxxxxx) wrote: > Hi! > > I have a case where my main process has two success exit codes, and > I'd like to run the ExecStartPost only if the exit code was > 0. However as I understand the documentation any exit code listed > for SuccessExitStatus is considered successful. I also listed the > alternative success return code in RestartPreventExitStatus, but > that's probably not necessary. > If I don't list the alternative exit code as success, the service > will be flages as failed, I guess... > > How would you solve this problem? Dou you actually men ExecStartPost=? Or is this a typo and you mean ExecStopPost=? How does your service definition look like otherwise? You can query the exit code with "systemctl show -p ExecMainStatus --value <service>". Lennart -- Lennart Poettering, Berlin _______________________________________________ systemd-devel mailing list systemd-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/systemd-devel