/srv/irclogs.ubuntu.com/2014/04/22/#juju-dev.txt

bodie_anyone know how to get the lbox tool to work properly on a headless host?00:25
bodie_or can I simply use the launchpad site to propose my merge?  isn't there some process for going through rietveld?00:26
bodie_we've been collaborating using a remote dev box00:26
perrito666bodie_: you need to set the... sensible-browser iirc, to nothing and it will print the link to authorize lbox00:36
bodie_okay, cool00:41
bodie_perrito666, I think I've already done that, because it's giving me the link, but I thought I had to visit the URL on the same host00:42
perrito666bodie_: nope00:43
bodie_perrito666 -- http://paste.ubuntu.com/7303428/ -- this is what I get after authorizing it from another host00:43
bodie_ah, might be working now00:44
perrito666did you d the whole confirmation dance? it is not as straight forward iirc00:44
bodie_it looks like it's working but now it's telling me to auth with my google account, and that's not working yet.00:53
bodie_Also I thought the MR description had to be 50 words, not 50 characters.  lol00:55
rick_h_bodie_: hah, 50 characters for the first line00:56
rick_h_and then more details after that allowed00:56
bodie_ah.....00:56
bodie_well, that is a very terse description then, lol00:57
rick_h_ex https://github.com/juju/juju-gui/pull/24900:57
rick_h_the 50 chars is becoming a common convention00:57
bodie_I mean, I crammed the whole MR description into the 50 characters thinking it was the limit.00:57
rick_h_lol, no, just that first line00:57
bodie_It's not quite twitter speak....  :$00:57
rick_h_so that a one line diff is reasonable and no-wrap00:58
bodie_ahhh00:58
rick_h_but you can expand/list/etc in the body of the commit00:58
bodie_yeah00:58
=== Ursinha is now known as Ursinha-afk
bodie_is there a way to amend that?00:58
bodie_I keep getting invalid user or password after it asks me for my Google creds.  I've tried with binary132 as well as binary132@gmail.com, I know I'm using the correct password, and I authorized it on Rietveld....00:59
=== Ursinha-afk is now known as Ursinha
arosalesaxw: hello01:01
axwarosales: heya01:02
arosalesaxw: were you working with thumper and davechenney on the power enablment bits?01:02
axwarosales: nope01:02
arosalesaxw: ah ok01:03
axwarosales: is there something broken?01:03
arosalesaxw: do you happen to know if any other juju core folks were working on power enablment besdies thumper and dave?01:03
arosalesaxw: getting a seg fault and I know there is a kernel bug opened just not sure if it was recently resolved . .  .01:04
axwarosales: I think waigani has been fixing some of hte tests...01:04
axwand wallyworld was looking at one stage01:04
axwI'm not sure if there was anyone else01:04
wallyworldthere were packaging guys looking at the kernel bug01:04
wallyworldnot sure of the status01:05
perrito666bodie_: your sso acct is not setup?01:05
bodie_sso?01:05
arosalesaxw: wallyworld: thanks for the info. Looking at https://bugs.launchpad.net/ubuntu/+source/gccgo-go/+bug/127562001:07
arosalesI think the fix may be in gccgo, just not sure when that fix is going to make it into trusty01:08
wallyworldarosales: yeah, i'm not up on the latest status sorry01:08
wallyworldi wasn't sure if it was just gccgo related or not01:08
perrito666bodie_: strange, can you pastebin the whole output? (omitting any info that you considered not public :p)01:09
bodie_it actually looks like Google was blocking my login from the VPS for security reasons :/01:09
bodie_giving it another go01:09
waiganiarosales: what is your email? I'll forward you the latest on that issue01:10
perrito666bodie_: oh01:10
arosaleswallyworld: no worries01:10
arosaleswaigani: also do you know the latest on https://bugs.launchpad.net/ubuntu/+source/gccgo-4.9/+bug/130475401:10
_mup_Bug #1304754: gccgo on ppc64el using split stacks when not supported <ppc64el> <trusty> <gccgo-4.9 (Ubuntu):Confirmed> <https://launchpad.net/bugs/1304754>01:10
arosalesI think this is the one we are actually hitting01:11
arosaleson -08 kernels we are ok, but anything more recent we consistantly seg fault01:11
bodie_THERE we go.  thanks google....01:12
bodie_https://codereview.appspot.com/90130044 ! ^_^01:12
waiganiwaigani: if I remember correctly, I think the two are related - dave is the best one to ask - hopefully the email I sent will be helpful01:12
arosaleswaigani: yup they look to be related01:15
josehello, guys! I have a fix for a file in juju-core, and I was wondering what's the correct way of making an MP, as I've seen codereview.appspot.com used in the past02:31
rick_h_jose: yep, reitveld is used with a tool called lbox to submit patches.02:32
joserick_h_: erm, would you mind helping me to propose an MP?02:33
joseI think I fixed https://bugs.launchpad.net/juju-core/+bug/1309805 as the description mentioned02:33
_mup_Bug #1309805: LXC / Local provider machines do not boot without default-series <config> <local-provider> <lxc> <juju-core:Triaged> <https://launchpad.net/bugs/1309805>02:33
rick_h_jose: I'm looking for the doc. Not done it myself. :)02:33
joseoh, ok, thanks :)02:34
rick_h_jose: http://bazaar.launchpad.net/~go-bot/juju-core/trunk/view/head:/CONTRIBUTING02:34
joseblargh, I suppose I need to check better for files like that in the future :P02:34
josethanks rick_h_ :)02:34
rick_h_jose: all good, thanks for going through the process02:34
josenp :)02:35
joseuh, looks like I'm getting an error when proposing03:20
joseRuntimeError: maximum recursion depth exceeded in cmp it says03:20
axwwallyworld: do we have a sprint topic about bulk API?04:18
axwmachine provisioning is getting pretty chatty now04:18
wallyworldaxw: yes, i think so, i remember seeing it04:22
* axw hunts04:22
wallyworldBulk cloud API calls (both scalability, and things like port-ranges)04:23
wallyworldi also recall reading some prose04:23
axwhmm that's a bit different04:23
axwI'm talking about bulk Juju API calls04:23
axwbulk is maybe the wrong word04:24
axwI mean combining API calls, for example04:24
wallyworldi know what you mean, it's there somewhere04:24
axwok04:24
joseoh hey wallyworld, have a minute?04:25
wallyworldhi sure04:25
joseI'm having some problems doing a proposal for juju-core04:25
joseerm, let me find the error04:26
wallyworldok04:26
joseok, so when I try to do 'bzr switch' it tells me the branch doesn't exist, or if I do 'lbox propose -bug=bugnumber' I get http://paste.ubuntu.com/7304413/04:28
joseI was wondering if there's a way to do a proposal in codereview.appspot.com without using this tools, if the branch is in LP and I already have a bug number04:29
wallyworldhmmm. i've not seen that error before, but it looks like your initial creation of the branch missed something04:30
wallyworldwhat does bzr info say04:30
wallyworldlaunchpad is the means by which the landing bit picks up and merges the code04:30
wallyworldcodereview.appspot.com is an ancilliary tool because some folks didn't like launchoad initially04:31
joselet's check bzr info04:31
wallyworldbut lp is the main tool via which stuff needs to be proposed04:31
josebzr info gives the same error I think04:33
joseso, saying I want to get https://code.launchpad.net/~jose/juju-core/init-comment-default-series merged into lp:juju-core04:33
josewould an MP be enough/good? or I still need to go through rietveld?04:34
wallyworldno, mp is fine by me. i prefer lp04:34
joseok, let's link the bug and do an mp then :)04:35
wallyworldbut your bzr setup is broken though if bzr info doesn't work04:35
josebzr info is broken when I execute it via cobzr04:35
josebut if I do it with bzr, it gives the following output:04:35
josehttp://paste.ubuntu.com/7304444/04:36
* wallyworld sighs - cobzr is another tools which was not needed04:36
joseI should recognize the CONTRIBUTING file complicates the process x100004:36
wallyworlddoes the contributing file talk about cobzr? that is unfortunate if it does as it's just not needed and makes things much harder04:37
wallyworldbzr, lightweight checkouts,and switch are all that's needed04:37
joseyeah, the contributing file talks about cobzr and lbox04:37
wallyworldsadly lbox is unavoidable since rietveld is the review tool most people like using04:38
wallyworldanyways, do your mp in lp for now and we'll get it reviewed04:39
joseawesome, thanks :)04:40
josewho should I set as the reviewer? or should I just leave that blank?04:40
wallyworldleave it blank - i'll look at it now04:42
josethank you!04:42
josehttps://code.launchpad.net/~jose/juju-core/init-comment-default-series/+merge/216660 is it04:42
wallyworldjose: the boilerplate environment.yaml file already has a commented out section for default series...04:45
wallyworld    # The default series to deploy the state-server and charms on.04:45
wallyworld    #04:45
wallyworld    # default-series: precise04:45
wallyworldi think we just want to add a comment in there to tell the user to uncomment defaultseries and set to precise or trusty as needed04:45
joseok, I'm modifying that line04:46
wallyworldthe juju init output does tell the user to edit the yaml file to suit04:46
wallyworldthanks very much for contributing04:46
joseno prob :)04:46
wallyworldit's great when we can get help with all the little paper cut issues like this as we often doesn't get the time to polish these user facing annpyances04:47
joseand, message changed04:49
wallyworldlooking04:51
wallyworldjose: sorry, i didn't mean change the juju init message. the extra juju init output is not needed. just add a line to the comment in the yaml boilerplate telling the user they should uncomment the default-series line and choose precise or trusty04:52
wallyworldprovider/local/environprovider.go04:53
joseoh, gotcha, gotcha :)04:53
josethat should do04:56
wallyworldjose: yep, i'll approve and the landing bot will pick it up. depending on what else is in the queue, it should land in say 20 minutes or so04:58
wallyworldthank you04:58
joseawesome!04:58
joseno prob, glad I could help :)04:58
joseshould I mark that bug as fix committed?04:58
wallyworldjose: no, that will be done automatically by launcghpad once it lands04:59
josegood then04:59
josethanks for approving!04:59
wallyworldnp. you'll get an email soon hopefully saying it landed04:59
josecool05:00
jamso quiet these days... :)06:48
=== vladk|offline is now known as vladk
=== vladk is now known as vladk|offline
=== psivaa-afk is now known as psivaa
=== vladk|offline is now known as vladk
vladkjam: morning08:43
jammorning vladk, how's it going?08:44
voidspacemorning all08:54
jammorning voidspace08:55
perrito666morning09:23
mgzhey perrito66609:24
wwitzel3hello09:37
voidspacewwitzel3: morning09:40
wwitzel3voidspace: hey, enjoy the holiday weekend?09:43
voidspacewwitzel3: yeah, very good thanks09:53
voidspacewwitzel3: my church has a big easter celebration weekend, so I've been to six meetings09:53
voidspacewwitzel3: so hectic, but great fun catching up with all my friends from round the country09:54
wwitzel3voidspace: nice09:54
voidspacewwitzel3: I'm just catching up with administrivia and then we should (could) hangout09:54
voidspacealso the bluebells are out09:54
voidspacewwitzel3: you have a good weekend?09:55
wwitzel3voidspace: I did thanks :)09:56
perrito666jam: ?10:01
jamperrito666: just finishing up another hangout, will be there soon10:01
yaguanghi all,does any one know how to specify a public ip pool when juju bootstrap with openstack10:37
yaguangwhen using neutron as network service10:37
yaguangas juju can't login the instance without a public ip10:37
jamyaguang: "use-floating-ip: true" in environments.yaml10:52
yaguangjam, I see that option, but juju complains  floatingip pool need to be specified10:53
yaguangjam, with neutron, you need to specify the pool to allocate a floating ip to instance10:54
mgzyaguang: can you ask in #ubuntu-server about the neutron setup you need?10:56
mgzyaguang: note, you don't really need public ips, provided you put the machines on a network you can route to10:57
yaguangmgz,  the problem is that with public ip, instance can only be accessed in netns10:58
yaguangs/with/without/10:58
jamvladk: my son's homework was pretty quick, want to do a hangout to get started on bug #131025511:58
_mup_Bug #1310255: juju-run failure /var/lib/juju/system-identity not accessible in HA <ha> <juju-run> <juju-core:Triaged by klyachin> <https://launchpad.net/bugs/1310255>11:58
jam?11:58
jamwwitzel3: do you have a handle on https://bugs.launchpad.net/bugs/1304407 ?12:00
_mup_Bug #1304407: juju bootstrap defaults to i386 <amd64> <apport-bug> <ec2-images> <metadata> <trusty> <juju-core:In Progress by natefinch> <juju-core 1.18:In Progress by natefinch> <juju-core (Ubuntu):Triaged> <https://launchpad.net/bugs/1304407>12:00
natefinchjam, wwitzel3: this is the review: https://codereview.appspot.com/89900043/    this is the branch: lp:~natefinch/juju-core/045-amd64plz12:02
natefinchwwitzel3: it just needs a test that we pick amd64 if it's an option12:02
vladkjam: let's do it12:03
jamvladk: I'm in https://plus.google.com/hangouts/_/canonical.com/vlad-john12:06
voidspacewwitzel3: let me know when you're back12:23
voidspacehmm...12:23
voidspaceactually, I'll go on lunch12:23
voidspacewwitzel3: I'll catch up with you in a bit12:23
jamnatefinch: "juju ensure-availability" takes an '-n' parameter that is mandatory. Did you discuss this with Rog?12:28
jamI filed bug #1311083 because I think setting 3 is a sane default12:28
_mup_Bug #1311083: juju ensure-availability should default to -n=3 <ha> <ui> <juju-core:In Progress by jameinel> <https://launchpad.net/bugs/1311083>12:28
jambut I wanted to check if I missed some discussion12:28
jamhttps://code.launchpad.net/~jameinel/juju-core/ensure-availability-default-3-1311083/+merge/216706 or https://codereview.appspot.com/90160044 for anyone who wants a quick review12:32
jamok, this looks to be the conversation: https://codereview.appspot.com/81700043/diff/1/cmd/juju/ensureha.go#newcode5812:34
jamWhich is "a default of 1 seems wrong" which I agree with12:34
natefinchjam: I think 3 is the only sane default, and it's almost always useful to have a sane default13:26
jamnatefinch: the path from StateServingInfo into writing stuff to disk is *really* convoluted13:28
jamnatefinch: so I'm trying to fix EnsureAvailability so that it picks the default series based on the existing machines13:29
jamnatefinch: however, in client_test.go today, we don't actually *have* any state machines when we run the first EnsureAvailability command13:30
jamwhich is completely *not the way it would be*13:30
jamand it further has the bug that the StateServingInfo doc in the DB is only created when you *open* the State13:30
jamafter you've created machine-013:31
natefinchjam: the tests were where we had the most difficulty with this code.  I agree that we shouldn't be testing with zero state servers to start13:31
jambut I'm trying to reopen state, and getting "bad password cannot create the log db"13:31
rogpeppe1jam: the stateServingInfo doc is created at state initialize time13:32
rogpeppe1jam: unless we're upgrading13:33
jamrogpeppe1: but in JujuConnSuite there *is no machine-013:33
jamso there is no valid machines serving the state13:33
jamthere are13:33
jamrogpeppe1: so we have to create one, and then get the doc to be recreated13:33
rogpeppe1jam: yeah, that's wrong - the tests should add a machine before calling ensureavailability13:33
rogpeppe1jam: but the doc is still created13:34
rogpeppe1jam: even when there are no machines13:34
jamrogpeppe1: well, there is a doc, but it has no contents13:34
jamcreating the machine13:34
rogpeppe1jam: yeah13:34
jamdoesn't update the doc13:34
jamso you have to create the machine13:34
jamand then re-open the state13:34
jamfor it to put machine-0 in13:34
jamrogpeppe1: unless there is some other trick I should know about13:34
rogpeppe1jam: i don't understand what you mean by putting machine-0 in stateservinginfo - stateservinginfo doesn't have any machine info in13:35
rogpeppe1jam: unless you're actually talking about state *server* info13:36
jamrogpeppe1: if I do: _, err := s.State.AddMachine("quantal", state.JobManageEnviron)13:36
jamrogpeppe1: then it dosen't end up in StateServingInfo13:36
rogpeppe1jam: StateServingInfo doesn't have any machine info in13:36
jamrogpeppe1: so it still looks like there are no machines actually serving the state13:36
rogpeppe1jam: i don't understand your statement13:36
rogpeppe1jam: unless you're talking about StateServerInfo13:37
jamrogpeppe1: sorry, I think you're right about StateServerInfo13:37
natefinchbecause that's not confusing ;)13:37
jamjust a typo looking through similarly named things on 5 different object types13:37
rogpeppe1jam: and StateServerInfo *should* be maintained by AddMachine13:37
rogpeppe1jam: if it isn't, that's a regression and needs to be fixed13:37
rogpeppe1jam: but i'm pretty sure it is13:37
rogpeppe1jam: otherwise the logic wouldn't work13:37
jamrogpeppe1: I'm pretty sure just doing AddMachine doesn't put any MachineIds into StateServerInfo13:37
rogpeppe1jam: it definitely should do13:38
jamEnsureAvailability does13:38
jamso the tests that start with EnsureAvailability(1) work13:38
jamand bootstrap does13:38
jamso in real-life it works13:38
jamrogpeppe1: but in real life we never have a case where there is no machine-013:38
jambecause life starts somewher :)13:38
jamahh,, ffs, I can't just poke EnsureAvailability either because that notices that len(VotingMachines) == 013:43
natefinchjam: like I said, the tests is where we had the most problems with this code :)  There's just a lot of moving pieces and a lot of mongo quirks to work around.13:44
jamnatefinch: the fact that JujuConnSuite doesn't match a bootstrapped environ is bad here13:44
jamnatefinch: it is the only place where you have a Mongo running and *no* machine to host it13:45
rogpeppe1jam: about a million years ago I tried to change things so the dummy environ creates a bootstrap machine13:45
rogpeppe1jam: but it broke many many tests13:45
jamrogpeppe1: I can imagine13:46
jamit makes it hard to do things like "machine-0 is *this* type of machine"13:46
rogpeppe1jam: because we have loads of tests that assume that the first machine created has id 013:46
jamrogpeppe1: *right* now I think I can make it work if I can re-open State so that we trigger the upgrade logic13:46
* rogpeppe1 goes and looks at the code13:46
jamrogpeppe1: state/open.go has newState() which calls createStateServersDoc13:47
jamwhich notices that if "len info.MachineIds == 0" then it will create it.13:47
rogpeppe1jam: yeah, it needs to13:47
rogpeppe1jam: because we might be in an upgraded environment13:47
rogpeppe1jam: but state.Initialize calls state.Open13:47
jamrogpeppe1: sure, it just means I can backdoor it.13:47
rogpeppe1jam: you should not need to13:48
jamrogpeppe1: I have to create the machine, then get it to run the upgrade ode13:48
jamcode13:48
rogpeppe1jam: AddMachine with JobManageEnviron *should* add the machine to StateServerInfo13:48
jamrogpeppe1: it doesn'tt13:48
jamflat out13:48
jamit doesn't13:48
rogpeppe1jam: i thought there were tests that tested that specifically13:48
jamrogpeppe1: so I see maintainStateServerOPs13:49
rogpeppe1jam: State.AddMachines calls maintainStateServerOps13:49
jambut when I'm testing it, I see len(VotingMachineIds) == 013:49
rogpeppe1jam: which should do that13:49
rogpeppe1jam: there are no *voting* machine ids13:49
rogpeppe1jam: but there will be a non-voting machine13:49
jamrogpeppe1: if there is only machine-0, why wouldn't it be voting ?13:50
jamrogpeppe1: ok, PEBKAC, it wasn't the test I fixed that was failing, it was the other tests.13:50
rogpeppe1jam: that's a reasonable question.13:50
jamthat *weren't* creating a machine13:50
rogpeppe1jam: BTW i think the logic should create a voting machine id unless NoVote is true13:51
jamrogpeppe1: well, again, that isn't the "standard" path that we're going to get machine-0 is it?13:52
jammaybe it is13:52
jamthe first step is just AddMachine(the thing I just started)13:52
rogpeppe1jam: AddMachine should add the machine to the voting servers13:53
rogpeppe1jam: i'd be surprised if it doesn't13:53
jamrogpeppe1: so it might, I'll have to double check that now that I've sorted out which tests are actually failing13:53
rogpeppe1jam: ok13:53
jamI certainly expected that we would always have 1 voting machine13:53
rogpeppe1jam: i believe we do13:54
jambut stuff broke because we never created machine-013:54
rogpeppe1jam: (after the first machine is actually created)13:54
jamand I fixed that for one test, and the others broke, and I thought it was my test that was breaking13:54
jamok, we have a voting machine after AddMachine13:56
rogpeppe1jam: good. everything seems to be working as it should then.13:58
rogpeppe1jam: BTW i think it might be reasonable if AddMachine also took its series from the state server machines by default14:02
rogpeppe1jam: because then at least we know that calling juju add-machine will work14:03
jamrogpeppe1: I think having PreferredSeries return the state server arch instead of LatestLTSSeries would be ok, but I think that is more of a conversation that we need to bring up for discussion.14:05
rogpeppe1jam: yeah14:05
jams/arch/series/14:06
wwitzel3voidspace: https://code.launchpad.net/~wwitzel3/juju-core/008-ha-rsyslog14:08
jamnatefinch: rogpeppe1: so AXW's comment seems to me that he wanted a default to mean "preserve the existing availability"14:11
jamI would be fine making the default 0, and have that interpreted on the server as 3 or whatever N is currently running if N != 114:12
rogpeppe1jam, natefinch: i have a version of https://codereview.appspot.com/70770043/ that consists of entirely automatic changes and uses "errgo" rather than "errors" as the errgo package identifier. i'd quite like to get it in, but it would be nice to have advance approval because of the overheads of proposal.14:12
jamrogpeppe1: as this is not in the critical path to release, I can't commit the time to reviewing it today (especially since I'm 1.5hrs past EOD already)14:13
rogpeppe1jam: which comment?14:13
jamrogpeppe1: https://codereview.appspot.com/90160044/14:13
jamabout the default N for ensure-availability14:13
rogpeppe1jam: ok. but are you amenable to the change in principle?14:13
* jam goes to spend time with the familyd14:13
rogpeppe1jam: +1 to making the default the current number14:14
jamI haven't particpated in the discussion enough to really contribute there.14:14
jamI think we had gotten to the point of "yes we should use errgo", but I wasn't a voting member of those discussions14:14
rogpeppe1jam: i had a "LGTM but please use errgo for the package identifier"14:19
rogpeppe1jam: which is basically what i'm doing now14:19
rogpeppe1jam: but that was a little while ago. the LGTM might have expired.14:19
rogpeppe1jam: i can make the changes in about 15 seconds, but lbox proposing it takes ages.14:20
bodie_hi guys, can I get a review on our MR?  https://code.launchpad.net/~binary132/juju-core/skeletal_actions/+merge/21665114:25
bodie_it's a little hefty14:25
bodie_whenever you have time14:25
bodie_thanks in advance :)14:25
bodie_rietveld at https://codereview.appspot.com/9013004414:26
wwitzel3voidspace: http://www.rsyslog.com/sending-messages-to-a-remote-syslog-server/14:29
natefinchrogpeppe1: what does swapping in errgo get us right now?  Do we get file/line numbers for those errors?14:29
rogpeppe1natefinch: it doesn't change any existing external behaviour, but it means we lose our dependency on github.com/errgo/errgo and it sets us up for the next stage.14:30
rogpeppe1natefinch: and, yes, we might get file/line numbers for those errors14:30
natefinchrogpeppe1: keeping that code from bitrotting seems worthwhile14:31
rogpeppe1natefinch: (but those errors aren't really the important ones as they're easy to grep for)14:31
rogpeppe1natefinch: that code has already bitrotted (i just do it from scratch each time), but the conversion program may bitrot14:31
stokachuis the ProvisioningScript the api call i would use to "juju run" a shell script before any of the hooks are run?14:33
natefinchrogpeppe1: ok, just do it.  If the code compiles and the tests pass, then I don't think anyone can argue too much.14:34
rogpeppe1natefinch: cool14:34
=== Ursinha is now known as Ursinha-afk
stokachuor is an api command available that allows me to run abitrary commands on a machine before any hooks are executed14:37
natefinchstokachu: what are you trying to accomplish?14:41
stokachunatefinch: writing a plugin to do some initial setup on the machine before running a charm14:42
natefinchstokachu: you can always do add-machine, set up some stuff, and then deploy --to it14:42
stokachunatefinch: by doing juju run or juju ssh?14:42
natefinchstokachu: juju run, yeah.  You can do juju add-machine, juju run --machine 1, juju deploy foo --to 114:43
stokachuso how do i do it through the api?14:44
stokachui want to pass it a script to run14:44
stokachuwith the api i want to be able to add-machine, upload a script via sftp or something, then execute it before a charm is deployed14:45
stokachui can add-machine through the api just fine14:46
natefinchstokachu: there's a RunOnAllMachines api endpoint14:46
=== Ursinha-afk is now known as Ursinha
stokachuso that endpoint RUnOnAllMachines, does it support passing a script over the wire? or is it for running commands independently14:48
natefinchstokachu: looks like it just takes a list of commands, not a full script14:50
stokachuok14:51
stokachuis the run commands done as root as well?14:51
stokachui dont have to worry about sudo or anything like in the charms?14:51
natefinchstokachu: yeah, it's run as the "ubuntu" user which generally has root privs14:52
stokachuok cool14:53
stokachuso essentially i could run juju scp, then call the api to execute that command14:54
natefinchstokachu: that should work, yeah14:54
stokachuis there an api for scp or does that have to be run manually, i couldnt find any reference to it in the code14:54
stokachuin the api section of the code anyway14:54
natefinchstokachu: yeah, scp doesn't use the API14:57
stokachuok cool, thanks man14:57
natefinchwelcome14:58
stokachunatefinch: last question, other than juju scp is there any other way to upload files to machine using the api?15:02
sinzuirogpeppe1, natefinch: I don't think Go van only import a master branch from git. Am I wrong?15:02
rogpeppe1sinzui: i'm not sure what you mean15:02
rogpeppe1sinzui: the only thing in Go that knows about branches is "go get"15:03
stokachumarcoceppi: maybe you know? ^15:03
natefinchstokachu: I don't think so.  What's wrong with using the juju client's juju scp?15:03
stokachunatefinch: if im on a remote machine with no juju client15:03
natefinchstokachu: I guess I don't know why you'd be on a random machine without juju, but with whatever code you're writing15:04
sinzuirogpeppe1, right. I  can "go get" github.com/juju/core/1.1815:04
sinzui^ rogpeppe1 I mean I can *not*15:04
natefinchsinzui: you can always use version control to get a branch before building it with go15:05
stokachunatefinch: yea just wanted the ability to interface with juju without relying on juju binary15:05
natefinchstokachu: but..... you have *code* that you're relying on somewhere.15:05
sinzuirogpeppe1, for CI and releases, I need to keep the branch info separate and I need another step to checkout that branch15:05
mgzcan I have a review on https://codereview.appspot.com/9031004315:06
mgzrogpeppe1: ^ you should be on holiday, no? (but if not... :)15:06
stokachunatefinch: yea but that doesn't necessarily mean i have to have juju installed with it15:06
sinzuinatefinch, That presumes a little too much. Currently, we use go get, then switch to the branch.15:06
sinzuinatefinch, Then  run godeps to pin all the branches to the correct version15:07
natefinchstokachu: well, otherwise you're just duplicating effort with what we have in juju client15:07
sinzuinatefinch, The new issue is that bzr urls has branch and (implicitly) repo, git only supports repo (implicitly master)15:08
stokachunatefinch: what if its library bindings15:08
sinzuiSO I need to change CI and Releases to gather another piece of information, the branch, and I need a step to switch to that branch when juju goes to git hub15:08
natefinchsinzui: yes... although go get launchpad.net/juju-core/1.18 wouldn't work anyway, since it would put the juju-core code in $GOPATH/src/launchpad.net/juju-core/1.1815:10
natefinchstokachu: not sure what you mean.15:10
sinzuinatefinch, It does work, but not that way. Release tarballs always exercise go-get, then switches to a branch and revision. The branch is a url. git is a name.15:11
natefinchsinzui: I guess I'm not sure what the problem is, if you had to go get and switch before, and you do the same with git.15:17
natefinchsinzui: does it matter if the switch target is a url or a name?  they're both just strings, right?15:17
sinzuinatefinch, There are some issues because a url enough information for CI/releases to get all the juju code. It is not with git. It is two pieces of information that I need to store now15:18
natefinchsinzui: oh, I see.15:19
sinzuior I create a pretend url with the extra information15:19
sinzuinatefinch, This is a niggle that makes CI transition to github awkward. Obviously it can be fixed in a day, but I was hoping that Go had a solution for the problem15:19
natefinchsinzui: there is a solution, but it requires us to do a little work ahead of time. You can make a redirector service that can translate, for example  juju.com/v1.18/juju-core into github.com/juju/juju-core (branch 1.18)15:20
natefinchsinzui: that's actually the "correct" way to solve this problem.... we've been going against the grain with godeps and using non-head branches etc etc15:21
sinzuiah, thank you natefinch. I forgot about that15:21
stokachunatefinch: if im writing an application using a api library i shouldnt need the actual juju command15:34
stokachuthe api server supports uploading of charms though15:36
natefinchstokachu: the juju client pretty much is an api library, and one that we keep up to date with the rest of our changes.  But I understand it may not work for all purposes.15:41
stokachui think it would be cool override cloud-init too15:43
marcoceppistokachu: you can use regular rsync15:59
marcoceppiyou just have to have ssh keys on that machine, and know the IPs15:59
stokachumarcoceppi: do i just supply it the ssh key15:59
stokachui think the api lets me get those ssh keys15:59
marcoceppi`rsync -avz ubuntu@<juju-machine-ip>:... ./`15:59
marcoceppistokachu: maybe, not sure15:59
natefinchstokachu: you can certainly override cloud-init, but there is almost certainly code in jujud that will assume stuff has been done in cloud-init.16:00
stokachuso i wanted to maybe utilize the provisioningscript api call to override cloud-init in a manual provider16:00
stokachubut it looks like it would be run after a machine is deployed16:01
voidspaceneed moar coffeez16:09
=== jamespag` is now known as jamespage
voidspacenatefinch: ping16:50
natefinchvoidspace: pacman (so much better than pong)16:51
voidspacenatefinch: hah, nice - I'll have to remember that16:51
voidspacenatefinch: so I'm working with wwitzel3 on the rsyslog issue16:51
voidspacenatefinch: we think we can do most of the work with the rsyslog configuration16:51
hazmathmm.. api-endpoints on trunk has degraded16:51
hazmathttp://pastebin.ubuntu.com/7308341/16:51
natefinchvoidspace: awesome16:51
voidspacenatefinch: with some extra work to update the config when available state servers change16:51
voidspacenatefinch: with the slight side issue (to be dealt with later) that new state servers possibly want all the previous logs too16:52
voidspacenatefinch: so we currently have separate config templates for nodes and stateserver machine16:52
voidspacenatefinch: nodes are currently configured to log just to the *first* state server machine16:52
voidspacenatefinch: changing that to have multiple rules logging to all of them is easy16:52
voidspacenatefinch: state servers only log locally (to a file)16:53
voidspacenatefinch: we need to change this to log locally *plus* to send all log messages generated on the machine to the other state servers16:53
natefinchhazmat: what's degraded about that?16:53
hazmatnatefinch, previously it would return the first line..16:53
voidspacenatefinch: obviously not to just forward *all* messages, or they would forward all the ones they received and every message would be logged an infinite number of times16:54
voidspacewhich might annoy people16:54
hazmatnatefinch, its now returning every possible state server address. the whole point of the method is for api clients to connect to the state server.16:54
voidspacenatefinch: sooo, we need an rsyslog rule that matches locally generated messages16:54
natefinchvoidspace: yeah, that sounds good.   definitely handling new servers added getting old logs is something that can sit in a todo for right now16:54
hazmatnatefinch, so private addresses, local host addreses need not apply. ipv6 addreses should only be shown on switch, etc. it breaks existing clients that were using the output previously16:54
voidspacenatefinch: well, we probably need to do adding new servers unless the info for all state servers is always immediately available16:55
voidspacebut that aside16:55
voidspace(we'll figure that out shortly)16:55
voidspacewe need a rule that can filter local messages16:55
natefinchhazmat: yeah, jam was looking at that too.  Certainly the localhost ones are just wrong (especially since you might legitimately have a local environment running on localhost).16:56
voidspacenatefinch: I'm currently scouring the interwebs for examples of matching local messages only16:56
voidspacenatefinch: is this something you know about or should I delve further into my search?16:56
natefinchvoidspace: I know less about rsyslog than probably anyone else on the team :)16:57
voidspaceI can see we have %HOSTNAME% available to the templates16:57
voidspacenatefinch: haha16:57
voidspacebut I don't think local messages will come in with hostname16:57
voidspacemaybe we can match on the *absence* of a hostname as we know the format of *forwarded messages*16:57
hazmatnatefinch, its also confusing because the notion with ha is that each entry would be a different state server16:57
voidspacethat sounds potentially ropey though16:57
voidspacenatefinch: ok, I'll continue16:58
natefinchhazmat: brb, gotta help with the kids for a second.  I think part of the idea is that IPs internal to the environment will work from inside environment, and the external ones might not.16:58
hazmatnatefinch, one of the primary users of the api is the cli client which isn't in the environment. notions of external/internal are definitely fuzzy17:00
hazmatfiled a bug on it to track  fwiw http://pad.lv/131122717:00
natefinchhazmat: the idea is that you dial all the addresses (staggered slightly) and use whatever one connects first.  I believe the way the CLI works is that when it connects to one, it resorts that one to the top of the list, so next time it's likely to connect first again.17:11
hazmatnatefinch, the issue is a bit more than that.. if this api is used by agents then result need to differ by login17:12
hazmatnatefinch, there's little value in an a cli client connecting to localhost, private ip addresses, or ipv6 (unless requested)..17:13
hazmatwhere as agents preferentially want the private addresses17:13
natefinchhazmat: right17:13
=== vladk is now known as vladk|offline
natefinchhazmat: probably the ultimately right thing to do is return the same list to everyone, but include the networkscope, so the consumer can decide what addresses is appropriate for itself.  the client would only look at public, agents would only look at cloudlocal, etc.17:17
hazmatyeah.. more incompatible output ;-)17:17
hazmatnatefinch, in that case (incompatible output) differentiating the state servers would also be good17:18
natefinchhazmat: can't keep the world frozen for forever :)    Really, the only problem with the current output (aside from the fact that it's not the same as what we had before) is that some of the addresses are ambiguous (localhost, 10. addresses from outside the cloud, etc)17:19
hazmatnatefinch,  well the current output is a regression for users of that cli command imo17:19
natefinchhazmat: the API servers are all identical... there's no reason to differentiate17:20
hazmatnatefinch, 'so the consumer can decide what addresses is appropriate for itself. '17:20
hazmatalso applies to multiple distinct endpoints.. even if resulting traffic is identitcal17:21
voidspacewwitzel3: example of having separate rulesets for local and received messages17:21
voidspacewwitzel3: http://www.rsyslog.com/tag/more-complex-scenarios/17:21
hazmatnatefinch, ie a client wants to grab a  set of ipv4 public addresses to round robin to.. how do they know their getting an ha set without servers identified distinctly17:22
natefinchhazmat: I'm not sure I understand.  You get a list of IP addresses the environment says are for the API.... what does that have to do with HA?  We always return addresses for all state servers.  If you're in HA, you'll get addresses from multiple servers.  What does the client need to know?17:24
hazmatnatefinch, i have a client that refuses to connect to an env unless its in ha mode.. how does it know the difference without state servers identified in the result?17:24
natefinchhazmat: juju status would show multiple state servers.  api-endpoints is not the call to make to determine if you're in HA mode.17:25
hazmatnatefinch, it is the call to get the api endpoints17:25
hazmatnatefinch, which is what the client needs to connect to.. if one server has 4 public ip addresses, how does the client distinguish to get only get the ones representing a unique set of endpoints for the state servers that it can talk to17:26
hazmatit can't unless the results also distinguish state servers in addition to endpoints17:27
natefinchhazmat: but it doesn't matter what API server it talks to17:27
hazmatnatefinch, the traffic doesn't matter, the connection being ha does.. ie. the client wants to be able to fall back to a different server, how does it know there's a different server to fallback to?17:28
natefinchhazmat: it has more API addresses it can connect, just round robin on those.17:29
hazmatnatefinch, if they all point to the same server?17:29
hazmatnatefinch, you expressed the desire to pass the information to the client, but your also saying let's not pass it because it shouldn't matter17:30
hazmatthat's not very consistent17:30
natefinchhazmat: the information I wanted to pass was the type of network address, not the machine that was behind it.17:30
hazmati'm saying it does matter if the client wants to know that there are multiple vms it can connect to17:30
hazmatwhy should the client try a bunch of addresses for a machine it may know it can't talk to ...17:30
hazmatbecause that machine is down now.. when if it knew which addresses mapped to the state server, it could just fallback to the next actual server17:31
natefinchhazmat: it just seems like you're trying to overload api-addresses.  There's juju status if you want to know the status of the state servers17:31
hazmatnatefinch, its already been overloaded17:32
hazmatnatefinch, i'm trying to clean it up.. you suggested breaking compatiblity already.. i'm saying well let's give the clients all the info they need.17:32
natefinchhazmat: well, we could return yaml document with each server and a list of addresses with what type they are (public, cloud local, etc)17:41
hazmatnatefinch, sounds good17:41
natefinchhazmat: probably not something we can do this week, though. We're pretty slammed, and a ton of people are off at gophercon17:42
hazmatnatefinch, yeah... i'm already on site17:43
hazmatnatefinch, its a regression though in the dev version, so it would be good to fix up or make compatible at least for the next stable, not sure when that's scheduled17:43
natefinchhazmat: pretty sure that'll be post-vegas.   But we should be able to target it for that, I'd think.17:44
natefinchhazmat: I wonder if we should have tests external to juju-core that show any break in compatibility with old versions.  Obviously they wouldn't be able to test everything, but simple things like this could at least be caught and discussed / noted in release notes.17:47
natefinchhazmat: I gotta run to a doctor's appointment, back in an hour or so.17:48
=== natefinch is now known as natefinch-afk
hazmatnatefinch-afk, yeah.. part of the issue is that the functional regression suite is only hit a small fraction of the surface area (bootstrap/destroy-env/deploy/add-unit/relation/expose etc)17:50
hazmati should setup some sort of ci for some of the extant plugins17:51
hazmatnatefinch-afk, hmm.. although i just ran into an interesting case and regression as a result of the same.. i'm currently spanning regions with manual provider which used to work fine.. but with 1.19 breaks because  the machines initially connect on public, get the cloud local address, and attempt to reconnect back with that cloud-local addresses which is broken since the machines are on different cloud-local/subnets, resulting in down machines.17:57
hazmathttp://paste.ubuntu.com/7308797/18:01
=== hatch__ is now known as hatch
=== vladk|offline is now known as vladk
=== natefinch-afk is now known as natefinch
bachi sinzui, can i pick your brain about logging in to charmworld?20:05
sinzuibac sure20:21
bodie_thanks for the feedback natefinch20:26
bodie_:)20:26
bodie_i'll reply in thread20:26
natefinchbodie_: no problem.  Glad to have this work getting done. I don't remember if I said so, but the code looks generally good.20:27
bacsinzui: may have to wait util tomorrow...20:36
=== vladk is now known as vladk|offline
=== hatch___ is now known as hatch
stokachuso im trying to write some code against juju-core but i keep hitting this error: http://paste.ubuntu.com/7310622/23:11
stokachui thought someone brought this up previously but couldnt find it in my irc logs23:11
stokachucmars: i get that same error when trying to build your juju-nat plugin too23:12
stokachucmars: have you run into that issue before?23:12
Guest46215stokachu: looks like you've pulled tip of code.google.com/p/go.crypto which breaks juju. Go's lack of proper dependency mgmt sucks. you can run godeps -u dependencies.tsv to get the correct revision23:19
stokachuGuest46215: ah perfect that worked23:20
stokachuGuest46215: thanks!23:20

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