[15:24] <leehambley> hi all, can anyone tell me if there's a way to skip starting services when they're installed, I'm fighting netatalk and samba, i've implemented a policy-rc.d which forbids samba/etc -
[15:24] <leehambley> my policy rejected them both, and I see the syslogs from my policy-rc.d - but I still ended up with /etc/init/{sa,nm}bd.conf files, and the services both started
[15:25] <erkules> ahoi, I want to 'globaly' define a tmpfile pass a value from pre-start to exec. For that I would like to do something like env ARGUMENT=$(mktemp) in the 'global' section. It doesn't work and using a fixed path is no solution for me :(
[15:32] <xnox> leehambley: echo "manual" | sudo tee /etc/init/NAME.override
[15:32] <leehambley> xnox: thanks -- is the lack of support for policy-rc.d a known problem?
[15:32] <xnox> leehambley: where NAME is whichever job you want to override, e.g. sabd.override to override sabd.conf
[15:32] <leehambley> thanks
[15:33] <xnox> leehambley: there is full support for update-rc.d in saucy and up, not sure about policy-rc.d. Need to check....
[15:33] <leehambley> thanks
[15:34] <xnox> erkules: you should define environmental variables outside of any block, and then set it in pre-start, and read it in script/post-start.
[15:35] <xnox> erkules: http://upstart.ubuntu.com/cookbook/#export ? should work. Can you pastebit your example that is not working?
[15:40] <leehambley> xnox: after creating that file, do I have to do anything to make upstart recognise it, it doesn't seem to be working
[15:40] <xnox> leehambley: define "working" ? what did you put into the .override file and what did you expect to change?
[15:41] <xnox> leehambley: if it has stanza "manual" init, upon boot that job will not automatically start.
[15:41] <leehambley> xnox: I expected that service not to start when it's installed, and not to restart if I kill it (kill -9 <thepid>)
[15:41] <leehambley> the second part isn't working
[15:42] <leehambley> I put the word manual(\n) in that file
[15:45] <erkules> xnox: I can setting an variable 'outside' works. But doing some expansion stuff doesn't i.e. env ARG=$(mktemp) or env ARG=`mktemp` then ARG is set to $(mktemp) and not the output of the command mktemp
[15:46] <xnox> erkules: correct. do env ARG=; in pre-start ARG=$(mktemp); and then in exec/script/post-start/pre-post-stop it should be available.
[15:47] <xnox> erkules: also please paste your job. Why don't you do everything in "script; end script"? =)
[15:49] <xnox> leehambley: first you need to stop them with "sudo stop NAME"
[15:49] <leehambley> alright, roger that
[15:49] <xnox> leehambley: then in .override put "pre-start script \n stop \n end script"
[15:50] <xnox> leehambley: thus any attempts at starting/respawning jobs will be, well, denied.
[15:50] <leehambley> thanks, that looks just like a bigger hammer than "manual"
[15:51] <xnox> leehambley: yeah. manual, only negates "start on" conditions, but package upgrades do "start NAME" explicitly more or less.
[15:56] <leehambley> thanks for the clarification xnox :-)
[16:18] <erkules> xnox: http://paste.debian.net/10938/
[16:18] <erkules> xnox: Your workaround didn't worked. So I did it statically 
[16:23] <xnox> erkules: can errors go to stdout or stderr? as they will be collected into /var/log/upstart/mysql anyway.
[16:23] <xnox> erkules: ah you are parsing it as well...
[16:24] <erkules> xnox: every tip is welcome
[16:24] <erkules> :)
[16:32] <xnox> erkules:" A script section cannot modify the value of a variable defined in a job configuration file for other script sections."
[16:32] <xnox> sigh
[16:32] <xnox> erkules: http://upstart.ubuntu.com/cookbook/#environment-variables
[16:36] <erkules> xnox: thats why my original plan was to do ARGUMENT=$(mktemp) outside. Which as you rightly told is not working.