Question about lifetime of environment variables in job files

Matthias Urlichs smurf at smurf.noris.de
Fri Oct 31 06:26:03 GMT 2008


Hi,

Garrett Cooper:
> env VAR=0
> 
Don't forget that environment variables are inherited from parent to
child. That's _it_.

> echo "POST MESS: $VAR"

... so this would probably print zero, if it was actually used to stop
your job.

Since that job exits on its own, pre_stop isn't run.

To fix that, you might want to write a precognition module. Unfortunately,
Kernel support for crystal balls still seems to be missing. ;-)

-- 
Matthias Urlichs   |   {M:U} IT Design @ m-u-it.de   |  smurf at smurf.noris.de
Disclaimer: The quote was selected randomly. Really. | http://smurf.noris.de
v4sw7$Yhw6+8ln7ma7u7L!wl7DUi2e6t3TMWb8HAGen6g3a4s6Mr1p-3/-6 hackerkey.com
 - -
"The world in which we live can be understood as a result of
 muddle and accident; but if it is the outcome of deliberate
 purpose, the purpose must have been that of a fiend. For my part,
 I find accident a less painful and more plausible hypothesis."
                 [Bertrand Russell]



More information about the upstart-devel mailing list