/srv/irclogs.ubuntu.com/2012/01/13/#upstart.txt

leehambleyI believe I have a problem with the umask stanza having no effect, could someone please take a look at config & terminal session here - https://gist.github.com/90f931594debddb3e97212:02
leehambleyI need files to be created ug+rw, and directories to be created ug+rwx - I'm sure this is correct.12:03
leehambleyI'm wondering if the `exec su -s /bin/sh -c 'exec "$0" "$@"'……….` trick is rendering the `umask` stanza useless12:06
codebeakerI posted the stanza:umask question to the mailing list, hope to receive an answer12:30
leehambleyhttp://stackoverflow.com/questions/8851848/upstart-unicorn-with-umask-ignored now at SO14:17
trondmmHi. I have an upstart job that starts several instances of another job. This works fine, and I can stop and restart each individual instance by passing the correct variables in the shell. However, I'd like to stop all instances by stopping the parent job. How do I do this?15:45
trondmmright now, "initctl stop parent" results in "stop: Unknown instance:"15:47
jodhtrondmm: Have the parent job run 'initctl list' then stop each instance found (see http://upstart.ubuntu.com/cookbook/#determining-how-to-stop-a-job-with-multiple-running-instances)15:47
jodhjodh: oh, so your "parent" job contains 'instance'?15:48
trondmmno, the parent only includes a script block that starts the sessions. basically for var in ...; do start instance; done15:50
jodhtrondmm: can you pastebin your config?15:51
trondmmI tried adding a pre-stop block which did the same loop, and stop instance, that didnÃ't work15:51
trondmmhangon15:51
trondmmhttp://pastebin.com/dMxDLQDU15:54
jodhtrondmm: 'start on started' is probably wrong here as the disks aren't mounted at that point.15:56
trondmmAh, OK. I've only actually started it manually so far.15:57
jodhtrondmm: also, you'll need to say "start wmsinstance ... || true". See http://upstart.ubuntu.com/cookbook/#develop-scripts-using-bin-sh and http://upstart.ubuntu.com/cookbook/#debugging-a-script-which-appears-to-be-behaving-oddly15:57
jodh'start on filesystem' would be safer. See upstart-events(7).15:58
jodhtrondmm: again, "chdir ... || true".15:58
trondmmright. 16:03
jodhtrondmm: for the problem you're mentioning you'll need to change 'script' in your parent job to 'pre-start'. This will make it an abstract job that will run "forever". See http://upstart.ubuntu.com/cookbook/#jobs-that-run-forever16:04
trondmmhey! that worked :) Thanks!16:08
jodhtrondmm: np. If you set a "stop on" for the parent job, you can use the for loop again in a 'pre-stop script' to handle stopping all the instances.16:10
trondmmactually, I can't get it work with pre-stop, but it works in post-stop16:13

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!