/srv/irclogs.ubuntu.com/2013/08/26/#juju-dev.txt

davecheneyhey, does anyone know if juju ssh 1/lxc/0 works ?00:04
davecheneycan you ssh directly to a contianer00:04
=== tasdomas is now known as tasdomas_afk
bigjoolshttps://bugs.launchpad.net/gwacl/+bug/121674403:11
_mup_Bug #1216744: Destroying role instances always leaves a VHD file behind <Go Windows Azure Client Library:Triaged> <https://launchpad.net/bugs/1216744>03:11
bigjoolsjtv2: so I explained azure to davecheney, Ian and axw and there was only medium swearing04:05
davecheneyhe was very restrained04:07
davecheneygold star04:07
jtv2bigjools: tell them they're naïve fools and won't know what hit them.04:07
jtv2Joking.04:07
bigjoolsto be fair most of it was from Ian and it's hard to tell the difference04:07
bigjoolsshhh he's here04:08
* davecheney is trying to figure out why juju status resolves an instance id to an Instance twice to talk to the state server05:29
bigjoolsI wondered why you had that look on your face05:30
davecheneybigjools: no, that is just my face05:31
bigjoolsjtv2: can you check the vhds container in whatever storage account you were using for azure - I think there's a bug as I have about 20 29.3GB blobs left behind.05:45
davecheneybzzt05:47
=== tasdomas_afk is now known as tasdomas
axwbigjools: http://paste.ubuntu.com/6027561/05:55
bigjoolsaxw: https://bugs.launchpad.net/juju-core/+bug/121676805:56
_mup_Bug #1216768: Azure provider: Authentication error when using public tools <juju-core:New> <https://launchpad.net/bugs/1216768>05:56
bigjoolsaxw: another nice bug https://bugs.launchpad.net/gwacl/+bug/121674406:15
_mup_Bug #1216744: Destroying role instances always leaves a VHD file behind <Go Windows Azure Client Library:Triaged> <https://launchpad.net/bugs/1216744>06:15
davecheneyquestion about lxc07:19
davecheneyare local containers addressable on the local lan ?07:20
davecheneyie, do they DHCP from the host's network07:20
davecheneyor are they bound to 10.x addresses07:20
MACscrIm trying to use juju with local (aka, LXC). I already have lxc setup, but i did have to change the bridging in order for LXC instances to be accessible from other computers on the LAN. So instead of lxcbr0, i just have br0. juju doesnt seem to like that. Does juju only work when the bridge is NAT'ed?07:23
davecheneyMACscr: i don't think nat'ing is the issue here07:25
davecheneyyou've changed the name of the interface07:25
davecheneyjuju expects it to be called lxcbr007:25
davecheneyyou've shortened it to br007:25
davecheneyi think if you fix that07:25
davecheneyit'll work07:25
MACscrevery tutorial states to use br0 when setting up the public access07:25
davecheneyMACscr: sure07:26
MACscrbut i guess i can try renaming it07:26
davecheneybut juju is different :)07:26
MACscrright, its a shame its hard coded07:26
davecheneyMACscr: yup, it is hard coded at the moment07:27
davecheney_BUT_ it is hard coded to the default07:28
MACscrim 99% sure this change isnt going to work07:28
MACscras the juju probably wants to be its own private network so it knows what IP's its assigning, etc07:28
davecheneyMACscr: you're probably right07:29
MACscrwith dhcp, the ip isnt being assigned until its booted, not when its created07:29
davecheneyenviron.go07:29
davecheney39:const lxcBridgeName = "lxcbr0"07:29
davecheneyat the moment, the name of the bridge interface is hard coded07:29
MACscramazing that a developer would do that07:29
MACscrare there any developers in here that know if NAT has to be used with LXC on the actual host?07:33
davecheneythey did that because it is the default name of the LXC interface07:33
davecheneyubuntu@ip-10-248-6-186:~$ ifconfig lxcbr007:33
davecheneylxcbr0    Link encap:Ethernet  HWaddr ee:6f:ad:c0:96:9107:33
davecheney^ this is a fresh lxc install07:34
davecheneyi agree that it isn't as flxebile as one would like07:34
MACscryes, i know its default, but obviously its meant to be reconfigured07:34
davecheneybut it does sound like a reasonable default07:34
MACscrbut the name doesnt matter, the issue is that with juju needing it to be that way, i highly doubt anything it creates using the local method will allow any of those instances to be accessible outside the host07:35
davecheneyMACscr: i think you are right07:35
davecheneyi was incorrect there07:35
davecheneyi was focusing only on the first problem of getting the lxc provider working07:35
MACscrcan any developers concur with that statement of mine? That seems to be a pretty huge limitation of LXC and pretty much means it can be only used for limited testing08:11
jamfwereade: ping for when you're around. I had a question about "statecmd".08:51
fwereadejam, heyhey08:52
jamfwereade: I trust your return to Malta was met with great fanfare and celebration?08:52
fwereadejam, haha08:52
fwereadejam, it's nice to be back08:53
jamfwereade: so I updated "juju add-unit" to use the API instead of a direct state connection which seems good. rog mentions here https://codereview.appspot.com/13212043/ that we should probably get rid of statecmd (since it was only for sharing implementation between the API and the CLI).08:53
jamwhich is fine08:53
jambut I'm looking at AddServiceUnits08:53
jamand it does weird things like08:53
jamNewConnFromState08:53
jamso it can do Conn.AddUnits08:53
jambut why do we need conn?08:53
fwereadejam, for AddUnits I'm 90% sure we don't any more *except* that Deploy does (or might...), and it uses AddUnits internally08:54
jamfwereade: well the implementation of AddUnits is on Conn08:54
fwereadejam, the only reason for the conn in the first place is to access provider storage08:54
jamso it *feels* like if I'm getting rid of statecmd/addunit.go I should be moving Conn.AddUnit somewhere else08:55
jambut where?08:55
fwereadejam, api.Client, I think, is the ideal08:56
jamfwereade: we have api.Client.AddServiceUnits which is what I'm using. It is backed in the apiserver which uses state/statecmd/addunit08:56
jamwhich uses Conn.AddUnit08:56
jammy point is that it seems really strange on the server side08:56
jamto get a NewConnFromState in order to AddUnit on it.08:56
fwereadejam, sure; moving AddUnit up to client and sharing that implementation between AddServiceUnit and Deploy would be just fine as far as I'm aware08:57
fwereadejam, it's just fiddly because Deploy might need Environ access to upload a local charm08:58
fwereadejam, but we should be exposing that capability over the api regardless08:58
jamfwereade: conn.AddUnits isn't called by anyone except tests and statecmd as near as my grep-fu tells me08:59
jamconn.DeployService can call conn.AddUnits09:00
jamI don't particularly mind conn having AddUnits, it just seems strange to need Conn in the apiserver.09:00
jamAm I just wrong on that?09:00
jamhi rogpeppe09:00
jamI thought today was "Summer Bank Holiday" for you09:00
fwereadejam, no, I think Conn is really inappropriate there09:00
jamI know mgz is out.09:00
MACscrsorry to interrupt, but i had a dev question earlier. Did anyone read it? DaveChaney sent me here09:00
rogpeppejam: it is indeed the auguest bank holiday today09:01
rogpeppejam: i am not here :-)09:01
jamrogpeppe: I started a chat with fwereade about removing statecmd, I would be interested to hear your thoughts if your ephemeral self wants to chime in.09:01
jamMACscr: mgz is probably the best person to chat with, and he is off today for the UK holiday. He should be around by this time tomorrow.09:02
jamMACscr: thumper would  be another person to ask, but he is in AU so is usually gone by now.09:02
rogpeppejam: briefly, perhaps09:02
fwereadeMACscr, the RelationList question sent to juju-dev? sorry, just saw that09:03
jamI guess if you were chatting with davecheney then thumper is in a similar timezone.09:03
MACscrokie dokie. Thanksffor the tips09:03
rogpeppefwereade: what are your thoughts?09:03
jamfwereade: the one in IRC from a bit ago is about LXC needing lxcbr009:03
jamrogpeppe: so I'm happy to remove statecmd, but it revealed some other ugliness.09:03
jamnamely, it is using NewConnFromState inside the API server to call Conn.AddUnits.09:03
fwereaderogpeppe, I'm +1, the cli and the gui should be using the exact same implementation09:03
jamAnd he and I seem to agree that Conn shouldn't be used inside the API Server.09:03
fwereaderogpeppe, it's really all about the conn nastiness09:04
rogpeppejam: +1 to that09:04
rogpeppefwereade: yeah, we need to eliminate that09:04
fwereadejam, I don't really see the need for Conn at all once we're api-only09:04
jamrogpeppe: but it is unclear to me where to move Conn.AddUnits to avoid duplication.09:04
rogpeppefwereade: in particular we need a way to upload charms09:04
rogpeppejam: what else uses Conn.AddUnits?09:04
jamrogpeppe: we do, but "not yet" given that AddUnits doesn't actually upload anything09:04
jamrogpeppe: Conn.DeployService09:05
jamand statecmd.AddServiceUnit09:05
jamand some tests09:05
MACscrfwereade: im not to concerned about the name, thats an easy fix. My concern is about LXC by default being NAT only and i have a feeling juju will only work that way. Thus anything it creates with LXC wont be accessible outside the host.09:05
jamand the builddb charm09:05
rogpeppejam: all that will be inside state/api eventually, right?09:05
rogpeppejam: or can be, at any rate09:05
rogpeppejam: if we choose it to be09:06
jamrogpeppe: that is sort of my point. *Where* does the functionality in Conn.AddUnits go.09:06
rogpeppejam: into state/api, no?09:06
jamrogpeppe: why would it go on the client side?09:06
rogpeppejam: sorry, doh09:06
rogpeppejam: into state/apiserver/client09:06
jamrogpeppe: how does the current conn.DeployService call into that/09:07
jam?09:07
rogpeppejam: well the current conn.DeployService should also end up in state/apiserver09:07
jamrogpeppe: does Conn have an API connection?09:07
jamrogpeppe: I'd rather not have to move-the-whole-world to get one bit to land :)09:07
fwereadeMACscr, ah, sorry, I was thinking of the wrong question then; and mgz is the expert, but the answer is basically that juju *will* be handling container addressability, but will only be creating containers if the cloud has addresses available to assign to the them09:07
rogpeppejam: perhaps it's not appropriate to move Conn.AddUnits until we can do tat09:07
rogpeppethat09:07
jamMACscr, fwereade: I think this is about local provider09:08
jamas in your personal machine09:08
jamno "cloud provider" availabel09:08
jamavailable.09:08
MACscrfwereade: correct. Local09:08
rogpeppejam: no, Conn doesn't have an API connection.09:08
jamMACscr: how are IP addresses assigned?09:08
rogpeppejam: the point is that probably all the stuff that's talking directly to state inside the juju package can eventually move into state/apiserver09:09
jamMACscr: that is the key point that I can see. As we have to play some games with lxcbr0, and I don't know how that works with third-party DHCP assigning addresses09:09
fwereadeMACscr, the local provider is explicitly a dev tool; we're not currently planning to handle addressability from outside09:09
MACscrthe way i have LXC setup now, it gets the IP's assigned through DHCP from my router and the bridge setup is called br0. LXC isnt setup that way by default09:09
jamrogpeppe: k, for now, I'll get rid of statecmd, leave in NewConnFromState and file a bug about APIServer should not depend on Conn. Sound good?09:10
jamfwereade: ^^09:10
MACscrfwereade: ah, thats very disappointing. Very unrealistic to use a physical machine or full VM just for a single service09:10
jamMACscr: 'juju deploy --to" or the future container work handle both of those.09:10
rogpeppejam: i don't think you can get rid of statecmd completely yet, no? just gradually whittle it down as you implement the various CLI commands in the API09:11
jamrogpeppe: no, just getting rid of statecmd/addunit.go09:11
jamright09:11
jamI overstated earlier.09:11
rogpeppejam: SGTM09:11
rogpeppejam: it's just good to have an idea of where we're heading09:11
fwereadeMACscr, would you explain your use case a bit more? do you have a cloud we don't support, that you want to run a local provider on?09:11
* rogpeppe fades away again09:12
MACscrfwereade: I have a management server that i want to run some LXC instances on. Also, when i deploy openstack, i want to put multiple services like ceph-mon and nova, etc, all all the same 3 physical servers09:13
MACscrthe only servers that will be separate will be ceph-osd and the compute nodes09:13
MACscrkeystone, etc, as well will be on the 3 nodes i just mentioned09:13
MACscrand probably some other openstack services i dont know yet =P09:14
fwereadeMACscr, ok, I agree that it's nicer and cleaner to have your service units running in LXC containers, but you can colocate already without containers; you just don't get the benefits of isolation09:14
MACscroh, i wanted to install the juju-gui on my management node, that was my first and original request/problem09:15
jamMACscr: so for 13.10 we are hoping to natively support containers inside machines provided by another cloud (it already mostly works when MaaS is providing the machines). Which might sort this out in a better way. Then you can use "juju deploy --to" for all of the openstack bits you want on the same physical machine.09:15
MACscrso it seems with juju has to deploy the gui, it seems to require that it runs on a separate server (no idea why)09:16
fwereadeMACscr, we're actively working on manual provisioning, which would let you set up your containers as you prefer, but that isn't ready today09:16
fwereadeMACscr, not at all, but service units get fresh machines by default09:16
fwereadeMACscr, `juju deploy juju-gui --to 0` should put it right where you need it09:17
MACscrso 0 would pretty much be localhost?09:17
fwereadeoh, damn, sorry, fwereade gets it now09:18
fwereadeMACscr, on the local provider, I think that would *probably* work but is not recommended09:19
fwereadeMACscr, if you're dealing with actual hardware would you consider using maas for your environment?09:20
MACscrfwereade: huh? Why would i need two management nodes just for using juju-gui?09:20
MACscrone to deploy it and another one its deployed on?09:20
TheMuegood morning, just back from doc, now start the week ;)09:21
fwereadeMACscr, the local provider is not going to work with more than one physical node in play09:21
fwereadeMACscr, maas would require a maas server on top of the nodes it deploys, I think, if that's what you're saying?09:23
MACscrfwereade: I understand that. Local means local only, thus not accessible outside that host. Which then means i cant even use juju-gui unless i have two physical hosts if i want to access it on the lan09:23
fwereadeMACscr, tell me when I say something wrong:09:29
fwereadeMACscr, you would like to use the local environment on a single remote machine09:29
MACscryes09:30
fwereadeMACscr, and control it from outside that machine09:30
MACscryes09:30
MACscrwithout having to do port forwarding09:30
fwereadeMACscr, ok, on the understanding that this is outside design parameters, you *might* be able to deploy to machine 0 -- which will be the physical machine running the local environment -- and have it work transparently09:32
jamfwereade: I'm pretty sure local provider doesn't let you do machine 0, but the maas provider has reasonable LXC support (at least with thumper's pending patch)09:33
jamas in, the LXC nodes end up on br009:33
jamlike MACscr is trying today.09:33
MACscrthough i could settle at this point just being able to have juju-gui on my management node09:33
jamMACscr: doesn't "juju deploy juju-gui --to 0" do that?09:34
MACscri have no idea, i havent tried it09:34
fwereadejam, damn, how does it stop you? the proper way of stopping you doesn't seem to be there, but maybe it's been hacked in somewhere I didn't expect?09:34
jamfwereade: I could be wrong. I know it wasn't intended to work. :)09:34
jamMACscr: so you're talking about deploying openstack infrastructure. You sound like you want to use "local provider" but have it put stuff on things that aren't on the local machine, is that correct?09:35
MACscrnope, doesnt work, it tries to install it to an LXC container and thus gives me the 'error: net: no such interface'09:35
jam(as in, how are you going to deploy the openstack compute nodes, and the ceph stuff that you didn't want on the same physical machine?)09:36
MACscrjam: sorry guys, im not trying to confuse anyone. Lets forget openstack and just go simple for now09:36
fwereadejam, gaaah, ok, it won't work09:36
MACscri have a single server running LXC on it and they are all setup to get DHCP from the router and are using br0. lxcbr0 doesnt exist as that was the bridge that was just used for private nating.09:37
MACscrall i want to do is get juju-gui to work so i can deploy openstack to my physical servers and also setup a few amazon instances09:37
jamMACscr: but what is juju-gui interfacing with? What are you using it to deploy?09:38
MACscrid like to start simple and just get the amazon instances working, but i do want to use the gu to do that so i can start testing it09:38
jamthe amazon instances?09:38
fwereadeMACscr, then surely you can bootstrap on amazon and deploy the gui to machine 0 there?09:38
MACscrjam: I guess that would be just amazon to start?09:38
jamit sounds like you are mixing providers (some local, some amazon, maybe some openstack), which isn't something we support today.09:38
MACscrfwereade: no way, i dont want to use up a amazon instance just for the gui. thats just plain stupid09:39
fwereadeMACscr, juju will not run a single environment across separate clouds09:39
jamMACscr: juju bootstrap (creates the controller node), juju deploy juju-gui --to 0 puts the gui on the same node.09:39
MACscrfwereade: i never said anything about a single environement. The amazon instances are for my dns servers and I guess maas would just be for openstack09:40
fwereadeMACscr, the juju gui currently administers a single environment09:41
MACscrso i would have to deploy two of them?09:41
MACscror is that even possible09:41
MACscri guess i just dont understand why whatever system im running the juju commands from isnt the actual controller09:42
MACscrthus why the need to setup a different one09:42
MACscrfor just the gui09:42
fwereadeMACscr, if you're using an actual cloud, you can/should deploy it to the controller node09:42
fwereadeMACscr, so if you want to run stuff on amazon, bootstrap there and deploy to 0 and you're fine09:43
jamfwereade: with MaaS, could we run the juju bootstrap node on the MaaS controller node?09:43
jamthat's probably more an allenap question.09:44
fwereadejam, I'm not sure about that but I wouldn't expect a maas controller to "provision" itself09:44
jamfwereade: it seems really useful in the "small scale allow me to get stuff up and running with 3 machines" case.09:45
MACscrjam: um, it makes sense for efficiency purposes09:45
fwereadeMACscr, if you have hardware, you should be able to use MAAS, but that does currently demand an additional node to control MAAS as far as I am aware09:45
MACscrwhy in the world would the controller not be the same system that you are running the juju commands on?09:45
fwereadeMACscr, your particular use case *will* be satisfied when we have manual provisioning working; that's in progress09:46
jamMACscr: you might be running juju commands from your laptop, controlling Amazon nodes.09:46
jamthe Amazon nodes need to be able to talk to the controller node09:46
jamto coordinate activities.09:46
MACscrjam: yes, so if im running it from my laptop, its the controller, this should have the gui on it09:46
jamMACscr: running 'juju' is not the controller. The "controller" is a jujud process that is running for the other nodes to talk to.09:47
jamamazon nodes wouldn't have routing back to your laptop (in the general case)09:47
MACscrok, now thats making sense, but wouldnt that only be needed when its initially setup? I mean, after they are deployed, the controller wouldnt need to be up anymore would it?09:47
MACscrso i dont see why the amazon nodes wouldnt be able to talk to the laptop09:48
jamMACscr: as you add units, put more stuff out, they trigger hooks being run on each machine09:48
jamcoordinated by the controller.09:48
jamMACscr: my machines are all behind NAT and not directly accessible from a public space like Amazone.09:48
jamAnd it certainly wouldn't stay at the same IP address as I move around.09:48
fwereadeMACscr, manual provisioning is in progress (aside: that *would* allow you to add aws machines to an environment, assuming everything *is* mutually addressable)09:49
jamMACscr: juju doesn't just provision machines at one point in time and then disappear. It continually monitors the system to notice when machines leave, when new nodes get added and they need to be connected to the other nodes, etc.09:49
fwereadeMACscr, and will become useful to you in its second phase, in which we support manual provisioning of an environment controller (rather than just adding machines to an existing environment)09:50
MACscrfwereade: ok, its starting to make more sense now. Not that i agree with its design, but im starting to understand it09:51
fwereadeMACscr, ;p09:51
MACscrok, so a controller that is setup can only manage one type of cloud at a time?09:52
MACscrso if i deployed the gui to an lxc instance, it would only be able to deploy lxc instances?09:52
jamMACscr: that is correct (at present).09:53
MACscrand if wanted to deploy an amazon guests, i have to setup an amazon controller too?09:53
fwereadeMACscr, today, yes, but assuming your controller is accessible to ec2 instances, manual provisioning will allow you to include those in another environment09:53
MACscrso even if i only want to deploy and manage 4 amazon instances, i actually have to have 5 of them? one for the controller?09:53
MACscrwell i dont really care what the future holds. I need to figure things out with currently available features =P09:54
MACscrhope that didnt sound offensive, wasnt my intent09:54
fwereadeMACscr, if you're using the complete capacity of those nodes and *don't* want to run the juju controller on one of them then, yes, you'll need another node09:54
fwereadeMACscr, np, all I heard was "I am frustrated"09:55
fwereadeMACscr, otherwise you can bootstrap on amazon, giving you machine 0, and manually deploy some of you units onto that machine09:55
MACscryeah, its just frustrating when you though you found a tool that was going to be perfect for your particular need and then reality hits and find out its not as cool as you though it was09:56
MACscrthought*09:56
MACscrlol, i forgot the T twice09:56
MACscrits 5am, im expected to make mistakes =P09:56
fwereadeMACscr, no worries, and I'm sorry to disappoint you09:57
fwereadeMACscr, was I clear about aws?09:58
MACscrfwereade: yeah. I think so and I really appreciate both you and jam's time to help explain things to me09:58
fwereadeMACscr, for deploying openstack, we do recommend running on maas and that -- being an entirely separate thing -- does require its own hardware09:59
MACscrfwereade: hmm, so i couldnt install maas on the management node i have now?10:02
MACscrheck, maybe i could install that in an LXC guest on my management node?10:02
MACscrim trying to limit what i install on the actual management host OS10:02
fwereadeMACscr, you might be able to install it on your laptop, but maas provisions bare metal from scratch, and it won't be able to do that to itself10:03
fwereadeMACscr, assuming everything's addressable, though, I don't see why you wouldn't be able to do run maas locally and use it to provision your 3 physical machines10:04
fwereadeMACscr, that said, if you have anything running on those machines that you want to keep, don't do that10:05
fwereadeMACscr, maas will overwrite those machines with the ubuntu series juju asks for10:06
MACscrsry, my mac got angry and i had to reboot. It has been about 3.5 weeks since the last one10:10
MACscrfwereade: all machines or just ones i specify? I am assuming thats done through mac addresses or something like that?10:18
fwereadeMACscr, you register individual machines with the maas controller and it's then free to have its way with them10:18
fwereadeMACscr, just installing a maas controller shouldn't cause havok in itself ;)10:19
MACscrok, but just to verify, the maas server can be its own controller. Correct?10:22
MACscrso when it asks for the controller ip, i can just do 127.0.0.1?10:23
TheMuefwereade: ping10:31
fwereadeTheMue, pong10:31
TheMuefwereade: I'm just doing the changes for string options to be also "", while others like int options react with an error. we talked about it.10:32
fwereadeMACscr, sorry, didn't see: I'm afraid I don't know, #maas would be the place for someone who does10:32
fwereadeTheMue, ok10:33
MACscrthanks again for your time10:33
TheMuefwereade: but here I've seen that this also influences the reading of a config.yaml10:33
TheMuefwereade: today "" here is the same as null10:33
MACscrneat to see at least maas planned it right by allowing the gui to run on the same node as the controller =P10:33
TheMuefwereade: but with the change "" would be treaten as string while it is inappropriate for int, foat etc10:34
TheMuefwereade: what do you think about it?10:34
fwereadeTheMue, I don't think "" is a valid float -- AFAIK the "" handling was new to juju-core, so I think we're safe pulling it out10:36
TheMuefwereade: got aware of it in ConfigSuite and there TestParseSettingsYAML10:36
TheMuefwereade: that's good news. ;)10:36
fwereadeTheMue, except, hmm -- check the python10:36
TheMuefwereade: argh10:36
TheMuefwereade: I hoped you would not say this :D10:37
fwereadeTheMue, sorry :(10:38
TheMuefwereade: hehe, np, alsready looking10:38
TheMuealready10:38
* fwereade thinks a moment10:38
fwereadeTheMue, even if it does work in python, I am sorely tempted to classify that as a bug10:41
TheMuefwereade: after our discussion last week I would agree10:45
TheMuefwereade: but I'll look a bit more to be sure if we have to note this in the release notes10:45
fwereadeTheMue, thanks10:45
TheMuejam: https://codereview.appspot.com/12752044/11:58
=== gary_poster|away is now known as gary_poster
natefinchjam: do we have Juju icons and images I can use for the installer?12:20
jamnatefinch: I don't explicitly know of them, but I would look in the documentation branch at "lp:juju-core/docs"12:23
jamnatefinch: looking at it, though, juju.ubuntu.com doesn't seem to show the Juju logo (the inverted and upright juju symbol)12:25
jamyou can see it at https://jujucharms.com/12:25
natefinchYeah, that12:25
natefinchthat's unfortunate12:25
jamnatefinch: when he's around, maybe poke gary poster12:25
natefinchcharm store does though12:25
jamgary_poster: ^^ do you have nice Juju icons?12:25
jamfwereade: it seems like state/api.Client should really be an interface. I realize there is the "you should consume interfaces but return concrete types argument", but it seems really hard to break Client up into 50 one-function interfaces.12:29
jamfwereade: bonus points, though, APIConn already has Close() which just calls self.State.Close()12:30
fwereadejam, I'd fine with that so long as the testing overlaps properly :)12:30
fwereadejam, cool12:30
jamfwereade: one bit I'm not super happy with NewAPIConn is the DialOpts. We currently pass it through a bunch of layers, but I was hoping to hide it for the CLI.12:31
jamIs it ok to just use api.DefaultDialOpts ?12:31
fwereadejam, I'm ok with that12:32
gary_posteroh hey jam.  sory, didn't see you.  Yeah I have svgs somewhere.  Is that what you need?12:33
gary_posterjam, I was about to ask you if I mind if I share your email about the CLI API work.  That looks like exactly what I was hoping for, so far.12:34
jamgary_poster: svgs sound good for nate.12:36
gary_posterack, looking12:36
jamgary_poster: for the API stuff, I have one more step I'm putting together today, (hopefully)  but yeah you're welcome to share it.12:36
gary_posterthanks jam!12:36
natefinchgary_poster: an .ico file with multiple sizes would be ideal along with the svgs12:38
natefinchgary_poster: I'm working on the windows installer for juju and want to make it look perty12:38
jamnatefinch: well, you can create one if you get an svg, right? That is what "scalable" is all about.12:38
natefinchjam: yes, but if he already has one, that saves me some time wrestling with gimp :)12:38
gary_posternatefinch, ack. :-) I have a favicon.ico but that's it, and that's probably not what you need, yeah?12:40
natefinchgary_poster: I was looking at that one, it's likely just 16x16... I can make a multisize one from the SVG, that's ok.12:40
gary_postercool.  yeah it is 16x1612:41
jamfwereade: *sad face*, APIConn.Close() exists, but api.Client().Close() does not. Time to start writing code.12:43
TheMueback again12:44
TheMuefwereade: could you repeat your last question here? i'm not sure if i got you right acoustically.12:45
fwereadejam, there is a slight worry there in that Client is unique among api types in being legitimately allowed to close the underlying conn -- I'm starting to think maybe just returning an api.State is the best thing12:45
jamfwereade: api.Client is a pretty unique beast, though. :)12:46
fwereadejam, yeah, if it's commented it's probably fine12:46
jamfwereade: so *today* conn.Environ from NewConnFromName is used for "juju status" to provide conn.Environ.Name(), "environment.go" to report "conn.Environ.Provider()", and "upgradejuju" (presumably to upload the tools so that it can ask to be used?12:47
jamI'm surprised not to see deployer in there.12:47
fwereadejam, BTW, I don't necessarily expect delivery, but consideration would be worthwhile: the client API is entirely unbulky at the moment, and it would probably be good to make it more so12:47
jamstatus also directly calls "fetchAllInstances".12:47
jamfwereade: more focused on bulk-operations? Or have more extraneous stuff that is unused? :)12:48
jam(define bulky)12:48
* fwereade deadpans "the former"12:48
jamfwereade: you had commented on TheMue's unset changes, can you give it a look:https://codereview.appspot.com/12752044/ he seems to have responded to your requests12:49
fwereadejam, AFAICS the deploy command uses NewConnFromName12:49
jamfwereade: sure, but it uses conn.PutCharm which might touch self.Environ. It doesn't call conn.Environ stuff directly.12:50
jamvs status et al12:50
jambut a fair point. Conn itself is the object that is touching Environ12:50
jamand we need to be careful when porting commands across.12:51
fwereadejam, the whole Conn thing is kinda crack anyway because it's got an Environ with a config that's most likely wrong12:51
fwereadejam, anyone actually *using* conn.Environ is playing with fire12:52
fwereadejam, PutCharm is probably mostly ok12:52
jamfwereade: well, it is one of those "this needs to be exposed in the api so we can use it there instead".12:52
fwereadejam, because all it uses is the creds which don't change much, and the control-bucket, which is immutable12:53
jamfwereade: well status accesses the Name, which isn't something we expose elsewhere.12:53
fwereadejam, but the important point is that in general you cannot trust conn.Environ and would therefore, in an ideal world, never use it12:54
fwereadejam, if you want to know something, get it from the API ;)12:54
jamfwereade: do we have Client.Name() ?12:54
jamor Client.EnvironmentName() ?12:54
jam(eventually we want to put something like that into a Client.Status() sort of output.)12:54
jamx12:54
fwereadejam, we have EnvironmentInfo12:55
fwereadejam, sure, but I expected status would be composed server-side and sent down in one go regardless12:55
jamright, that was my Client.Status() as a single call12:56
fwereadejam, cool12:58
jamfwereade: https://codereview.appspot.com/12943045/ NewAPIClientFromName instead of NewAPIConnFromName if you want to give it a look13:17
fwereadejam, cheers13:18
jamfwereade: it would appear that api.State.Close is not re-entrant :( (It gives an error already closed if you call it again)13:22
jamwe had a test that Conn.Close() could be called multple times13:23
jamwhich I copiesd13:23
jambut then found the test wasn't actually checking the error return13:23
jamadding that to Conn.Close() didn't give any errors13:23
jambut for APIClient.Close() which just calls c.State.Close() underneath returns errors...13:23
jamfwereade: *should* Close be idempotent?13:23
fwereadejam, it's somewhat useful for tests -- defer an assert that something closes without error -- but I guess it's at the point where errors aren't really useful, so logging and moving on at a lower level is probably reasonable13:26
jamgary_poster: I poked the notes you shared with me a little bit. We changed one of the function names, etc.13:49
jamfwereade: I'm fine with it returning an error. I'm just asking if "already closed" should be an error?13:50
jamIt isn't for state.State.Close() it *is* for api.State.Close()13:51
fwereadejam, ah, I see13:51
fwereadejam, er, dunno13:51
fwereadejam, you're implementing the client, though... make it work however seems to make most sense there ;)13:52
jamfwereade: it is being passed up from rpc.Conn.Close() where it checks "if conn.closing: return errors.New("already closed")".13:53
jamI guess I can wait for roger to figure out what his thought was.13:54
jamand since it is an untyped error, I'm not a big fan of detecting it in api.State.Close() and suppressing it: "if err.Error() == "already closed": return nil"13:55
gary_posterperfect, thanks for updating the doc, jam.  I hoped that might happen, actually. :-)14:15
=== marcoceppi__ is now known as marcoceppi
natefinchjam: do we sign our installers to prevent the "publisher: unknown" dialog box from popping up during install?  If so, I'll need a canonical certificate I can use with the installer.14:42
TheMuefwereade: so, went through the whole stuff in pyjuju from all sides and i'm pretty sure we can make the change. interestingly i found something like "set foo=@filename" where the value is read out of he file14:46
fwereadeTheMue, yeah, I noticed that the other day, I have no intention of implementing it unless we have to14:58
TheMuefwereade: so far nobody seems to miss it ;)14:59
fwereadeTheMue, exactly :)14:59
sidneifwereade: oh, was about to file a bug on that friday :)15:08
sidneibut just because we expected the functionality to be there from pyjuju15:08
fwereadesidnei, oh bother15:08
fwereadesidnei, if it's used, please file a bug15:08
sidneipeople that didn't know it exists just used juju set foo="$(<filename)"15:09
sidneiwhich is slightly more annoying15:09
fwereadesidnei, yeah, fair point -- my thinking was just that if nobody had noticed yet, hopefully nobody would ever notice ;)15:10
sidneican't tell for sure how many people were aware of it from pyjuju land15:10
sidneihttps://bugs.launchpad.net/juju-core/+bug/121696715:16
_mup_Bug #1216967: Missing @ syntax for including file config <juju-core:New> <https://launchpad.net/bugs/1216967>15:16
fwereadesidnei, thanks15:16
* fwereade bbl15:16
jamcan anyone help me figure out why this gc.DeepEquals is failing?17:24
jamhttp://paste.ubuntu.com/6029469/17:24
jamis it different integer types in 'value' ?17:24
jamvalue in Config is "int64{0}" which is supposedly getting sent over the wire, but coming back over the API it is probably going via JSON and ending up a float?17:25
jamHow much do we need the type to be matched exactly?17:26
jamI'm guessing the test used to work because it talked directly to state and BSON saved the type17:26
jambut in going via the API and JSON, it now ends up as a float6417:26
jam*sigh*, confirmed17:26
=== tasdomas is now known as tasdomas_afk
natefinchjam: I'm sad that it default to float and not integer when there's no decimal part17:47
jamnatefinch: json numbers are floats18:07
jamI'm a bit surprised it doesn't print 0.0 with a . to make it obviously not an int.18:07
natefinchnumbers in javascript are floats. Numbers in json are text... in theory there's no reason why you couldn't parse 5555 into an int and not into a float... though I admit that's not really standard18:09
natefinchit actually never occurred to me that numbers in json should be restricted to floats. Seems like an unnecessary restriction just because javascript doesn't have integers18:10
natefinchfloats make me sad. They18:12
natefinchthere's just too much funny business at values far from zero18:12
niemeyernatefinch: You can easily do that with Go's json package19:27
niemeyernatefinch: http://golang.org/pkg/encoding/json/#Decoder.UseNumber19:28
gary_posterhey hazmat and mramm.  rick_h has discovered that upcoming chrome 30 does not approve of the websocket headers that pyjuju produces.  https://bugs.launchpad.net/juju-gui/+bug/1217011 .  Juju Core headers are fine.  First answer to http://stackoverflow.com/questions/11300694/chrome-20-websocket-handshake might describe cause, but this is preliminary.  Do we care19:28
_mup_Bug #1217011: error connecting to rapi ws from chrome dev channel (30) <juju:New> <juju-gui:Triaged> <https://launchpad.net/bugs/1217011>19:28
gary_poster?19:28
natefinchniemeyer: I'm actually not 100% sure what jam was talking about... but I'll forward that on to him, seems like that would be a good idea19:28
gary_posterRemediation looks like it would be in pyJuju19:28
gary_posterRisk would be that chrome 30 will come out within 2-4 weeks, and break GUI against pyjuju19:29
jamnatefinch: the issue is that we've lost the type information after round tripping. If you "fix" it to return an int, I can just use float64() on that param instead. I'm guessing round-tripping isn't important at that level, but it *could* be.19:31
natefinchjam: yeah, it's kind of one of those json things where you have to know what you put in and how to interpret it on the way out19:34
natefinchjam: it's specifically not self-describing19:35
hazmatgary_poster, i'll have a look20:08
gary_posterthanks hazmat20:20
thumpermorning20:54
natefinchMOrning20:54
thumpermramm: ping?20:57
mrammthumper: pong20:57
thumpercall shortly?20:58
mrammthumper: sure20:58
hazmatgary_poster, rick_h fix pushed21:24
gary_posterawesome thanks hazmat!21:24
rick_hhazmat: awesome, to both rapi/pyjuju? Will there be a release of the old juju?21:28
hazmatrick_h, the ws stuff only existed on the rapi branch, the update was applied there. no plans for new releases of pyjuju.21:29
hazmatthe 0.7 release branch is going to be in saucy but deprecated, primarily exists to support existing envs.21:31
rick_hhazmat: right, but I duped the error talking to pyjuju on canonistack with the dev browser. Users could hit this in the next month or so as the version updates.21:32
hazmatrick_h, the gui charm pulls from the branch to deploy its ws endpoint independent of the underlying pyjuju version21:33
hazmatrick_h, ie. try deploying the gui now to reproduce, should work21:37
hazmatrick_h, the issue will remain against existing gui instances unless their updated21:37
rick_hhazmat: ah ok. I had thought that the juju-gui WS endpoint was the juju node and rapi was only for development purposes.22:03
thumpermorning axw, DarrenS22:36
* thumper sighs22:36
thumpertab complete fail22:36
axwmorning thumper22:36
axwfeeling better?22:36
thumpermorning davecheney22:36
thumperyeah22:36
axwcool.22:37
thumpergoing through email tasks this morning22:37
axwnow I feel like shit :)  haven't slept well in a few nights22:37
thumper:(22:37
thumperthat sucks22:37
thumperI take lots of vit-c and multivitamins22:37
axwalways happens when I go away22:37
thumperespecially when on sprints22:37
axwlearnt about azure yesterday22:39
axwand now I know what simplestreams is used for22:39
axwand had lots of chats with davecheney22:39
axwso otherwise winning22:39
thumpercool22:40
davecheney<neo>I know simplestreams</neo>22:45
davecheneyi also know crsn22:45
thumperheh22:59
thumperwhere's wally?23:14
davecheneythumper: he's here23:14
thumperaxw: please poke ian for me23:14
axwthumper: he just stepped out23:14
davecheneythumper: he's asking the hotel for a new internet code23:14
axwback now23:14
thumperdavecheney: yeah, I know, but I couldn't help that one23:14
wallyworld_thumper: you rang?23:16
thumperwallyworld_: I did, see PM23:17
wallyworld_thumper: can you resend, my internet got disconnected after the code ran out23:18
thumperwallyworld_: the PM?23:18
wallyworld_yeah23:18
thumperthe email should be fine :023:18
wallyworld_ah email23:18
thumpergot that?23:18
thumperwallyworld_: or the pm this time23:19
bigjools*snort* <davecheney> i also know crsn23:43
davecheneytoo soo ?23:46
davecheneysoon23:46

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