/srv/irclogs.ubuntu.com/2018/06/28/#cloud-init.txt

ybaumyi need help with the OVF datasource http://pastebin.centos.org/876866/08:35
ybaumysmoser: you are here?08:39
ybaumyanyone ever used that OVF provider?08:45
BloqueNegrohi :)11:22
BloqueNegroi want to use cloud init on ubuntu 16.04 to enable a second interface on a newly created instance11:22
BloqueNegroany tips how to do that? everything i tried needs another reboot (e.g. using write_files to write to interfaces.d) or is ignored completly (e.g. a config file from the example i wrote to /etc/cloud/cloud.cfg.d/)11:23
BloqueNegroit drives me crazy11:23
smoserybaumy: are you trying to run on a cloud somewhere or just providing data locally ?13:23
ybaumysmoser: cannot get OVF to mount a iso at all. i am now switching to NoCloud datasource which atleast mounts /dev/sr0 find a user-data and meta-data file... but nothing happens13:41
smoserybaumy: i'd suggest using NoCloud rather than ovf13:41
smoserbut i'd be surprised if doc/sources/ovf/README does not work13:41
smoserand similar for nocloud13:42
smoser https://asciinema.org/a/13201313:42
ybaumy1. im not using ubuntu .. im using centos 2. like in the paste url earlier i just seems to recognize the OVF in datasource_list at all13:43
ybaumyok that cloud-localds i havent done13:45
ybaumyand im using vmware13:46
smoserybaumy: well... a.) try the copr repo to get newer cloud-init13:49
smoserb.) if it fails, run 'cloud-init collect-logs' and file a bug13:50
smoserybaumy: i'd also kind of expect the openstack centos image to work with nocloud identically to how the asciicinema demo for ubuntu did13:52
smosersomething from http://cloud.centos.org/centos/7/images/13:53
ybaumysmoser: thanks will try14:04
ybaumyworks!!!!14:13
ybaumyi had that seefrom: None in there14:14
ybaumyand removed it to see what happens14:14
ybaumythat was the problem14:14
smoserybaumy: so the centos image and nocloud "just worked" ?14:30
smoseri should make a ascii...spelling-thing of that too14:31
ybaumyno i have created a custom ovf image in vcloud director14:35
ybaumyi used copr cloud-init latest version14:35
smoseroh. ok. good.15:01
blackboxswhttps://code.launchpad.net/~chad.smith/cloud-init/+git/cloud-init/+merge/348000 is up for the azure case. I've not pushed logic to keep original fallback network_config  yet16:33
blackboxswsmoser: rharper ping when you have about 10 mins to talk upgrade path azure16:57
blackboxswI added scenarios to the bottom of the doc https://hackmd.io/aODzXfa_TOikNtYBLt8erA?both16:57
smoserblackboxsw: i'm here.17:10
blackboxswsmoser: joining17:15
rharperblackboxsw: smoser still going ?17:41
blackboxswyep join in on the fun17:41
rharperk17:41
smoserblackboxsw or rharper https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34871118:19
smoseror powersj18:19
smoserthat will go a long way to "fix" ing our gpg related errors18:19
blackboxswcouple comments on that branch https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34871119:22
blackboxswlooks good thogh19:22
blackboxsw*though, take 'em or leave 'em as far as my suggestions19:22
smoserblackboxsw: https://hackmd.io/jlq3C4qbSgurZ_DZ5GTiuw19:26
smoseri updated the top hunk of that to use log2dch --hackmd19:27
smoserblackboxsw: in your suggestion of less try/except...19:27
smoserhard to read in line..19:27
blackboxswahh excellent on hackmd output19:28
smoserbut i think that you'd have to pass in a "retries=(1)" in order to get a single run19:28
smoserin curtin's subp we do basically:19:28
smoser  subp() # first time19:28
smoser  for trynum, naplen in enumerate(...):19:28
smoser    subp other tries19:29
smoseri wanted to avoid the two 'subp' calls19:29
blackboxswohh shoot, right smoser yeah I only though through the retries part, forgot the initial :/19:29
smoseryeah. so that is why it is as it is.19:29
blackboxswyeah oops, +119:33
blackboxswwas thinking about appending to retries when enumerating, but that's just adding complexity in another place. :/19:34
smoserthe way its done here is actually a way the read_url logic could have been done19:35
smoserthe exception_cb stuff.19:35
smoseryour iterator can be anything, and decide to exit based on other things19:36
smoseralthough the context of the exception is important there.19:38
blackboxswsmoser: that makes more sense, I was just thinking a bit too simplistically (heh, and incorrectly) there19:44
smoserblackboxsw: i think at one point you suggested dropping the minion integration test20:30
smoseris that right ?20:30
smoserbecause all it does is veriy we write files that we already unit test write20:30
smoseri'm looking at20:31
smoserhttps://bugs.launchpad.net/cloud-init/+bug/177873720:31
ubot5Ubuntu bug 1778737 in cloud-init "salt-minion test needs fixing" [Undecided,New]20:31
blackboxswsmoser: yeah I mentioned that it really doesn't do much more than unit tests and validate that the minion package was installed.20:31
blackboxswwe could tweak it to install salt server on the instance that then we'd actually have something to test (full integration there020:32
smoserthe easiest way to fix that specific issue is to just rid ourselves of that test :)20:32
smoseri'm not opposed to installing server and configuring minion to talk to localhost20:32
blackboxswsmoser: you could drop it for now, I'll file a bug for a real integration test and can assign it to me to resolve20:32
blackboxswor you can assign the bug to me now and I can get it post this SRU. it'd be nice to not have a timing issue affecting CI, I didn't see how frequent the failure was20:33
blackboxswreading the bug20:33
blackboxswyeah I've seen those tracebacks fequently via journalctl. But was able to get a working minion talking to a non-local server fairly easily. it wouldn't be too hard to get that server setup locally for avoid a couple of the issues with trying to lookup a salt hostname etc.20:35
blackboxswit didn't involve too much config, if we can write_files  to seed the expected client key20:36
blackboxsw... in the server config20:36
blackboxswsmoser: yeah, I'm all for dropping the existing salt-minion test for the moment. it really doesn't do much. and can easily be referenced whenever we get to a better integration test for it20:37
smoserblackboxsw: ok. removal on its way20:52
smoserblackboxsw: https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34871920:55
blackboxswapproved https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34871920:56
blackboxswBTW, having  a datasource express different scoped update_event lists it reacts to for 'network' vs 'storage' is making update_metadata and clear_cached_data logic a bit complex as we now have to determine what cached attributes to clear across an update_metadata refresh. it'll be interesting how this solutioon shakes out.20:57
rharperblackboxsw: hrm, AFAICT there are separate things;  1) what does the cached metadata look like (this should always match what we fetched from the service  2) what does the ds/cloud-init do when (1) is complete and ds is configured to apply the update ?21:01
blackboxsw+1 on part 1.    for part 2, right we need to (today) also set ds._network_config back to UNSET or None to ensure that the updated metadata cached gets propagated  to ds.network_config, instead of the cache value there too21:03
rharperhrm21:03
blackboxsw... and we need to make sure get_data doesn't arbitrarily clear_cache_data on the _network_config attr by default21:03
blackboxswbecause that would ensure any subsequent call to ds.network_config would get the 'new' metadtaa21:03
rharperwell, I think we talked about decoupling the fetch of new data21:03
rharperfrom updating the ds object attributes21:03
blackboxswcorrect there too, crawl_data(read)  vs get_data (persist). but in this case get_data doesn't persist the _network_config attribute, that is done within each ds.network_config call.21:07
blackboxswso if ds.update-metadata is called with EventType.BOOT and ds 'network' scope wants to react to that event we perform the following:21:08
blackboxsw1. get_data (which calls crawl_data)  clears the generic ds.cached_attr_defaults and persists new values to them.  2. clear ds._network_config so the next call to ds.network_config (note no underbar) will generate the network config from fresh metadata.21:09
blackboxswif we don't clear ds._network_config on a datasource, then we expect that this datasource would continue to present cached original ds.network_config21:11
blackboxswI should have a diff here locally that I can push in the next few minutes to better explain21:11
rharperyes, I see what you;re saying;  we may need to let network_config property be a bit more complex and ask the ds for other states; maybe it could choose whether render the current value versus re-rendering based on whether the refresh indicated new settings (and we've a event flag saying we need to update)21:14
rharperI much prefer the network_config property handler deal with clearing rather thant other parts of the object resetting it underneath21:14
rharperbut let's see what you have in a diff and go from there21:15
smoserhtis is interesting https://jenkins.ubuntu.com/server/job/cloud-init-ci/21:20
smoserthe "averarge stage time" of the maas compat test either went up recently or is affected a bunch by the 700ms fails times21:21
smoser(it thinks average is 2m 3s, while reality seems more like 3m)21:21
blackboxswok finally pushed the changes to https://code.launchpad.net/~chad.smith/cloud-init/+git/cloud-init/+merge/34800021:45

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