[16:10] <PeterFA> If I source a file that doesn't call any processes in my start script, will that interfere with the PID stuff?
[16:23] <jodh> PeterFA: if the sourced script only sets variables, that's fine.
[16:24] <PeterFA> jodh: thanks.
[16:25] <PeterFA> What if I have an if/then bock where the else part (which is the golden path) calls the process, would the if/then and test stuff interfer with getting the right PID?
[16:30] <jodh> PeterFA: no since 'if', 'test' and '[' are all shell built-ins (to convince yourself, run "for i in if then else test [; do type $i; done").
[16:31] <PeterFA> jodh: thanks. This kind of scripting makes me a bit paranoid.
[16:32] <PeterFA> I wish Upstart had some sort of flag that says, "This next line will produce the PID we want. Track that one."
[16:32] <jodh> PeterFA: if you are only setting a few variables, you could just use 'env' maybe to avoid the external script? http://upstart.ubuntu.com/cookbook/#env
[16:34] <PeterFA> jodh: I source the script multiple times. I understand that even though a variable is set, it dies with each section, so after process is started, the post-start or stop sections won't be able to use those variables.
[16:34] <PeterFA> So, I just rebuild them every time.
[16:34] <jodh> PeterFA: also, if the job your are producing is a session job (?) you could use http://upstart.ubuntu.com/cookbook/#initctl-set-env. That way you could set the variables in the pre-start and have them apply to the entire job such that the main job process (script/exec) won't need to source anything :)
[16:35] <PeterFA> jodh: that would be a whole lot simpler, and I do want to make this into a session job. The reason is because I want the processes to have lesser priviledges as to not go all political on the data.
[16:35] <PeterFA> Or at least on the rest of the system.
[16:36] <jodh> PeterFA: are you using setuid+setgid at the moment then? http://upstart.ubuntu.com/cookbook/#setuid
[16:37] <PeterFA> jodh: no, not yet. I want to though. I guess now's the time for this step.
[16:47] <linguini> cd upstart && ./configure --with-local-libnih=../libnih # says unrecognized option: --with-local-libnih
[16:47] <linguini> I'm trying to compile upstart, following http://upstart.ubuntu.com/wiki/CompilingUpstart
[16:48] <linguini> Is --with-local-libnih obsolescent?
[17:02] <PeterFA> How do I figure out what  version of Upstart I'm using? It looks like from yum -list I'm using Upstart 6.2.
[17:07] <jodh> PeterFA: 'initctl version' shows you the running version of upstart and 'init --version' will show you the latest *installed* version.
[17:08] <jodh> linguini: no, that option is still there.
[17:08] <PeterFA> jodh: awesome, thanks. I'm on 0.6.2.
[17:08] <PeterFA> Ouch, no session init.
[17:08] <jodh> linguini: you should probably be looking at http://upstart.ubuntu.com/cookbook/#setting-up-an-upstart-development-environment btw.
[17:08]  * PeterFA wails in agony.
[17:09] <jodh> PeterFA: oooohhhh...
[17:09]  * PeterFA plots the ultimate destruction of RHEL6.
[17:09] <jodh> PeterFA: no setuid/setgid either.
[17:09] <PeterFA> start-stop-daemon?
[17:11] <jodh> PeterFA: that's part of dpkg so unsure if that'll be available on RHEL either ?!?
[17:12]  * PeterFA collapses and turns ghostly white.
[17:12] <PeterFA> I'm going to go get some lunch.
[17:12]  * PeterFA disappears grumbling.
[17:16] <linguini> jodh: Thanks; I wonder why my configure doesn't accept the argument...
[17:17] <linguini> jodh: Thanks for the link; I'll look at the cookbook settings instead.
[17:17] <jodh> linguini: what version of upstart are you trying to build?
[17:18] <linguini> jodh: bzr branch lp:upstart
[17:18] <linguini> (ala http://upstart.ubuntu.com/wiki/CompilingUpstart)
[17:22] <jodh> linguini: try running 'autoreconf -fi' then './configure --help|grep with-local-libnih'
[17:23] <linguini> jodh: autoreconf -fi # success
[17:23] <linguini> jodh: ./configure --help | grep nih # nope
[17:25] <jodh> linguini: have you definitely installed all the pre-reqs ("sudo apt-get build-dep upstart")? What does 'grep with-local-libnih m4/libnih.m4' give?
[17:25] <linguini> jodh: No; I haven't.  I'll dry that.
[17:32] <linguini> jodh: It's installing 30+ MB of stuff.  Clearly I was missing some build dependencies!
[17:38] <jodh> linguini: :)
[17:52] <linguini> jodh: That worked!
[17:52] <jodh> linguini: great.
[17:52] <linguini> GNU auto-* tools are mysterious to me.
[17:53] <linguini> Thanks; I'm now unstuck.