[systemd-devel] start service only on specific exit status of some prog

Marius Tolzmann tolzmann at molgen.mpg.de
Thu Aug 25 01:01:37 PDT 2011


On 08/25/11 07:09, Nick Jones wrote:
> On Wed, 2011-08-24 at 21:21 +0200, Lennart Poettering wrote: 
>
>> I have now added this to the TODO list. It won't be easy to add this
>> though, as execution extrernal processes synchronously is not an
>> option. More likely I'll add an additional prefix char to ExecStart=
>> (like "-") which would indicate skip-on-fail or so.
>>
>> Lennart
>>
> 
> Would it make sense to emit a virtual unit label if a given unit fails?
> For example if X.service fails during its execution, then the virtual
> target X.service.failed is emitted.
> 
> The ugly side is that a package might end up with a number of service
> files that do almost the same thing, or require a forest of symlinks, to
> enable behaviour based on the outcomes of dependent units.

i really love the simplicity systemd offers.. so i was initially looking
for a way to maintain it and to do more complex conditions anyway - but
this complex logic can be processed outside of systemd if systemd
provides a way to just import the result.

the conditional checks we currently need are for example: hostname
matches pattern, userid still valid, ip-address X configured on any
device, etc..

bye, marius..

-- 
Dipl.-Inf. Marius Tolzmann <marius.tolzmann at molgen.mpg.de>
----------------------------------.------------------------------
MPI f. molekulare Genetik         |
Ihnestrasse 63-73, D-14195 Berlin |   ==> MarIuX GNU/Linux <==
Phone: +49 (0)30 8413 1709        |
----------------------------------^------------------------------
God put me on earth to accomplish a certain number of things.
Right now I am so far behind..
   ..I will never die.         <by calvin from calvin&hobbes ;)>


More information about the systemd-devel mailing list