[17:09] hey guys [17:09] I'm using post-start to block until a service is ready [17:10] I was under the impression that if a post-start script exits non-zero the service will then stop [17:10] but I guess that's not documented to be the case, and maybe it just isn't [17:10] thoughts? [17:31] frew: dont you want that in pre-start? [18:15] uh [18:15] no I don't see how that would make sense [18:16] I want to run the main script, and then block till it's ready [18:17] maybe im confused whatyou're trying to do [18:17] yeah sorry [18:17] so like [18:17] imagine you have a web server [18:17] and it takes like, 10s before it actually listens on port 80 [18:18] becuase you have some sort of ruby , or whatnot that takes time to do the initial compile? [18:18] you can add a post-start that wget's port 80 over and over till it gets an actual return [18:18] right exactly [18:18] the problem is [18:18] I'd like the post-start script, if it takes to long, to give up and mark the whole thing as failed [18:20] does something else trigger off of this event? [18:30] well [18:30] if you do start $foo [18:30] it will block until post-start completes [18:30] so naive scripts do indeed [18:31] frew: i just tested, and an exit code of 1 in a post-stop doesnt kill the already-running process [18:31] but [18:31] yeah I know; I just want it to :) [18:32] if you manually check [18:32] and issue a 'stop' inside your post-start [18:32] then it will shut it down [18:33] I thought I tried that [18:33] how do you do that? I tried literally stop $svcname [18:33] so in my test i did this [18:33] post-start script echo "sysrqd: this is a post start the next line is a stop" | $ILOG stop [18:33] oop, formatting is wrong [18:33] ill pastebin it [18:33] https://pastebin.mozilla.org/8869640 [18:34] ok just a single stop. [18:34] huh [18:34] yeah [18:34] any idea if that will make start exit non-zero? [18:34] not a huge deal but that would be nice [18:34] i think it just sends a term to the process [18:35] at least, thats what it appears to do [18:35] right.