Wednesday, 2014-09-10

*** pcrews has quit IRC02:36
*** flaper87|afk is now known as flaper8706:34
flaper87Shrews: I actually didn't use the `:` because of what jroll said06:35
flaper87not sure what's the best thing to do there06:35
chmouelgood morning07:26
*** cdent has joined #dox09:34
*** l_a_m has joined #dox12:29
l_a_mhi12:30
jrollShrews, flaper87, I've always used '-' for this in the past, e.g. infra/trusty-ironic13:19
jrollhiya l_a_m :)13:19
flaper87jroll: good to know13:19
flaper87I'm using it now too13:19
flaper87jroll: mmh, I'm not a docker expert and you seem to know something about it :D13:20
flaper87how can I run a service at "boot" time13:20
flaper87:P13:20
flaper87?13:20
Shrewsjroll only pretends13:20
jrollflaper87: I've written a dockerfile or two :P13:20
jrollyeah13:20
jrollmostly pretend13:20
flaper87ohhhhhhhhhhhhhhhhhh ok ok...13:20
jrollflaper87: anyhow, you want RUN or ENTRYPOINT13:20
* flaper87 stops asking embarrasing questions13:20
jrollI think it's RUN that can be overridden during 'docker run', ENTRYPOINT cannot13:21
flaper87jroll: CMD*13:21
flaper87:D13:21
jrolloh13:21
jrollyeah13:21
jrollok, so you're quizzing me I see :P13:21
jrollI haven't finished my first coffee, that isn't fair13:21
flaper87LOL, I just happened to have read that now13:21
flaper87\_/? <- backup coffee for ya'13:21
* jroll double fists13:22
* jroll types with his nose13:22
jrollShrews: how's the ironic dox file, I'm eager to try it13:24
jroll(slash help if there's still stuff to do)13:24
Shrewsjroll: some issues i'm trying to work around in regard to setting up stuff. mostly minor13:26
jrollcan I play? :)13:26
Shrewsyeah. gimme a minute13:27
Shrewsor 313:28
jrollok, no rush13:28
jrollShrews: gah, ironic is so loud right now13:40
Shrewssrsly13:40
jrollShrews: anyhow, they have the add section to add those files before prep13:41
Shrewsjroll: oh, so ironic's issue is that our tests fail unless you install ironic (b/c of the stevedore ext loading).13:42
jrollaha13:42
jrollok, I'll play around13:43
jrollstarting with a fresh vm, though, so might take a bit to get setup13:43
Shrewswe can do the ADD stuff, like zaqar, but the tests fail. that's why i added the multi-command command13:43
jrollI see13:43
Shrewswhich negated the need for the ADDs13:43
jrollbut then requirements are installed at runtime13:43
Shrewsright13:43
jrollwhich defeats half the purpose, no?13:43
* flaper87 is having a hard time creating a docker image that executes zaqar in background when it starts13:44
Shrewswell, depends on how dox is intended to be used13:44
jrollyeah13:44
jrollbut I don't want to install deps every test run :/13:44
Shrewsjroll: and also one reason i added the WIP for the --keep option (so we can easily re-run tests in the same container w/o the setup)13:44
jrollahh13:44
Shrewsbut mordred's handling of commands is funky... so i want to change that13:44
jrollok13:45
Shrewscommands should either be a list or string, yet it seems to be treated as both.... funky13:45
* Shrews thinks it should just be a string13:45
flaper87Shrews: would it be crazy to wrap the commands in an13:45
flaper87ops13:45
flaper87in an "sh script"13:45
Shrewsflaper87: that's what i'm doing13:45
flaper87Shrews: sweet, looking forward to that13:45
flaper87I think that will probably do the trick for me13:46
Shrewsflaper87: https://review.openstack.org/#/c/120413/1/dox.yml13:46
flaper87ah well, I was thinking to do that in dox directly13:47
Shrewsflaper87: well, we CAN do that too. comes out the same13:47
flaper87get the commands from dox.yml, wrap them all in an sh13:47
flaper87yeah but if we do it in dox, we can have a cleaner dox.yml13:47
flaper87commands: |13:48
flaper87  blah13:48
flaper87  blah blah13:48
flaper87etc13:48
Shrewsthe | doesn't work. we'd need....13:48
Shrewscommands:13:48
Shrews  - blah13:48
Shrews  - blah213:48
flaper87ah yeha, that13:48
Shrewsi'm open to either way. that's my goal to fix today13:48
Shrewsflaper87: i'll try it your way first13:48
flaper87Shrews: +1 sounds good13:49
jrollShrews: I wonder if dox should do 'python setup.py develop' before running tests, like tox does13:53
Shrewsjroll: that fails13:53
Shrewsfor ironic, at least13:53
Shrewssome setuptools weirdness13:54
* Shrews has tried many things13:54
jrolldafuq13:54
jrollhuh13:54
* jroll will play13:54
Shrewsyay!13:54
Shrewsjroll: but that's what the 'pip install -e .' command is doing13:54
Shrewsit's the new recommended way to do that, iirc13:55
Shrewsmordred probably knows why13:55
Shrewsjroll: do you know if you can mount a directory onto the container *during* 'docker build' ?13:58
jrollhuh.13:58
jrollyeah, there's a VOLUME command13:59
Shrewsi looked at that, but not sure that does what i want13:59
jrollyou want to bind mount it?13:59
jrollor just add it to the container?13:59
jrollas in, do you want changes synced13:59
Shrewsjroll: what i'd like to do is mount, say, the ironic source directory and do the requirements install *then*, rather than at command runtime14:00
jrollyeah, I would probably use ADD for that, the RUN rm -rf ironic14:01
Shrewsi guess that's one way14:02
jrollbut idk if that's the best way14:03
Shrewsjroll: it's probably better to do that at command runtime anyway, in case requirements change14:04
jrollwell, I'm thinking if requirements change, you rebuild the container14:05
jrollor grab the latest container from upstream, I should say14:06
Shrewsthe test image comes from upstream, not the container14:06
jrollright14:07
jrollbut if there is an ironic-trusty image14:07
Shrewsi don't think we'd want to rebuild that all the time14:07
jrollwhy not have the deps already installed14:07
Shrewsyou could potentially need *a lot* of images14:07
Shrewsunless you just want the absolute latest one based on current master14:08
jrollyeah, I would see an image for each milestone, plus master14:09
jrollif someone wants one in between, they can build from source14:09
*** pcrews has joined #dox14:15
Shrewsmordred: how committed are you to this '-c' option and the extra_args stuff? How useful is that?14:27
mordredShrews: well, running arbitrary commands and asking to run just one test is a frequent thing people want to do15:18
mordredalso, jroll - pip install -e . does the same thing as python setup.py develop - but it uses pip for all of the dependency management, not easy_install15:18
jrollright, ++ on using pip15:19
jrollI always wondered why we used setup.py to do that15:19
mordredbecause insanity15:20
mordredShrews: you're on a mac? docker/dox works non-insanely? mac was a question I got asked the other day15:20
jrollinsanity. as we do.15:22
chmouelmordred: it doesn't work due of the issue with binded mount15:56
chmouelthere is a github issue open for that, with some ugly hack using fusemount and other15:56
chmouelhttps://github.com/docker/docker/issues/402315:56
chmouelseems to have stalled,15:57
*** cdent_ has joined #dox16:27
*** cdent has quit IRC16:29
*** cdent_ is now known as cdent16:29
Shrewsmordred: i do my dev on my linux laptop. but i have used docker on mac. it uses an ubuntu vm for the docker server16:55
Shrewsthey package it with virtualbox16:56
Shrewsmordred: so, the way multiple commands is handled now just does not work. like, at all. In order to run multiple commands (like blah and foo) with docker, you have to enclose them like so:  sh -c 'blah && foo'17:39
Shrewsmordred: so handling commands from existing tox.ini's is a bit more complicated17:39
Shrewsmordred: and this -c and extra_args stuff complicates it even more17:40
Shrewsso, i'm just not quite sure how to fix this in a sensible way that people would expect it to work   :/17:40
Shrewsideally, we'd toss this around in a dox mailing list, but that does not yet exist17:41
Shrewsi guess we could use a [dox] tag on openstack-dev17:44
Shrewsnot sure if that's appropriate though17:44
mordredShrews: actually, I mean, people do it with crazy projects all the time - why not?17:50
mordred(also, sorry I haven't been hacking as much the past two days - turns out people want to have all sorts of crazy meetings with me when I get back from vacation)17:51
Shrewsmordred: insanity17:51
* pcrews can attest to Shrews' multiple commands observations: http://paste.openstack.org/show/109676/17:59
ShrewsTNETENNBA... lol18:00
pcrews'tis a go-to test string :)18:01
pcrews'overnumerousness' is a favorite too18:02
* Shrews thinks pcrews came here to drink milk and kick ass... and he's all out of milk18:04
pcrewsSo for the multiple images patch - https://review.openstack.org/#/c/119705/18:34
pcrewsFrom looking at it, it allows one to specify multiple images and dox will then run all of prep + command and whatnot on the images (run same stuff on many images).  Tests look good for this, btw.18:34
pcrewsHowever, the docs - https://github.com/stackforge/dox (under Advanced), make it seem like the goal of multiple images is to specify many image/prep/command chunks that may differ (this also allows for run same junk, just possibly w/ repetitive yaml).18:34
pcrewsIs the target to eventually hit many-images-doing-different-stuff?  Asking as I'm poking + documenting :)18:34
Shrewspcrews: we were tossing around the possible need for being able to things like 'prep' per image, because obviously that could be a very image-dependent action (apt-get vs. rpm)18:45
Shrewss/to things/to do things/18:45
Shrewsnot exactly sure what our "target" is yet. this project may morph drastically. or it may die. i think we're all just feeling it out, atm18:47
pcrewscool - gracias!18:51
Shrewspcrews: One idea I had for this multiple command dilemma is if there is a single command, execute as normal on the docker command line. If there are multiple, save them into a shell script into a .dox directory of the current directory, then just execute that script on the docker command line.18:59
ShrewsNot sure how the -c/extra_args stuff would interact with that then, but I'm just brainstorming18:59
Shrewsalso, mordred ^^^19:00
mordredShrews: we _could_ use ansible to execute the commands in the docker container ...19:01
* mordred hides19:01
Shrewsmordred: uh huh. yeah. and we could also redo dox in java19:01
pcrewsShrews: that makes sense and aligns with everything I've read for doing the same in docker (consolidate into a 'master' script and run that guy...)19:02
pcrewsAlso, we might need to change the way 'commands' is in the yaml file?  As it stands, it doesn't seem to preserve the individual components very well:19:03
pcrewsINFO|dox.runner|['docker', 'run', '--privileged=true', '--rm', '--user=pcrews', '-v', '/home/pcrews/git/dox:/src', '-w', '/src', 'dox_dox_test', 'python', 'setup.py', 'testr', '--slowest', 'echo', 'TNETENNBA!!', 'env', 'sudo', 'service', 'mysql', 'restart', 'ls', '-al', '/usr/bin', 'mysql', '-uroot', '-e', '<', 'SHOW SCHEMAS'] returned 119:03
Shrewspcrews: yeah. it would require making it into an array, like 'prep'19:03
Shrewscommands:19:03
Shrews   - cmd119:03
Shrews  - cmd219:03
Shrewsthe | is wrong for this19:04
pcrewscool, the baileys in my protein shake hasn't incapacitated me too badly then :)19:05
* pcrews also thinks about mordred's ansible proposal and imagines an 'obfuscated infra' contest...19:07
openstackgerritpatrick-crews proposed a change to stackforge/dox: Document multiple images in dox.  https://review.openstack.org/12054319:13
openstackgerritDavid Shrewsbury proposed a change to stackforge/dox: Better support for multiple commands  https://review.openstack.org/12056219:40
Shrewspcrews: mordred: my POC ^^^^19:40
Shrewsalso, chmouel and flaper8719:41
Shrewsand jroll !19:42
jrollhi19:42
jrollDO NOT MERGE means "don't look at this" right? ;)19:42
Shrewsjroll: you don't have to do anything with it if you don't want. low priority, obviously.  :)19:43
jrollI kid19:43
Shrewsjust an fyi19:43
* jroll looks19:43
jrollShrews: looks reasonable, assuming we don't need extra_args19:44
chmouelShrews: the syntax feels makefile'ey imo19:44
jrollotherwise could just .extend(extra_args)19:44
jrollchmouel: dunno, it's the same syntax as the prep section, etc19:45
Shrewschmouel: i don't know how to simplify executing multiple commands any simpler than listing them  :)19:45
chmouelyeah, i complain i complain but i don't see anything else either ;)19:45
jrollShrews: do we want extra_args in there, though, really?19:45
ShrewsI could add some makefile target support though, if you prefer  :)19:45
chmoueland this has been used in ansible as well19:45
Shrewsjroll: i could see that being useful IFF the command to execute is 'testr'. The extra args could be a single test to execute19:46
Shrews(per mordred's example earlier)19:46
jrollhmm, ok19:46
chmouelShrews: hahah, that would get me back in the late 90s when i was listening to darude and discovering that thing called linux :)19:46
jrollShrews: I could also see it being extra commands19:47
Shrewshonestly, i'm not sure how to make the two play nice yet19:47
* Shrews hoping to spark discussion/ideas19:47
jrollyeah19:47
jrolljust throwing out initial thoughts19:47
jrollkeep in mind I barely know how this thing works19:47
Shrewsjroll: i'm just trying to make your life harder.19:48
jrolloh, ok19:48
Shrewsfeel free to ignore me  :-P19:48
jrollI like making life harder19:48
jrollbuilds character19:48
openstackgerritpatrick-crews proposed a change to stackforge/dox: Document multiple images in dox  https://review.openstack.org/12054319:49
*** lifeless has joined #dox20:20
lifelessoh no peoples20:20
openstackgerritA change was merged to stackforge/dox: Document multiple images in dox  https://review.openstack.org/12054320:20
Shrewsrun. hide. anarchy20:20
*** mr_jolly has joined #dox20:36
*** mr_jolly has left #dox20:36
*** flaper87 is now known as flaper87|afk22:22

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