/srv/irclogs.ubuntu.com/2018/04/11/#cloud-init.txt

smoserblackboxsw: i'im goin gto upload with the IBMCloud to ubuntu01:20
smoserjust the ubuntu/devel as it is01:20
blackboxsw+1 smoser01:37
apollo13hi, I am testing with the NoCloud provider and noticed that cloud-init will try to reconfigure if I change the instanceid; is there a way to only allow cloud-init to run once09:17
apollo13this is currently on a fedora atomic image09:18
=== shardy is now known as shardy_afk
=== shardy_afk is now known as shardy
blackboxswapollo13: I think you could touch /etc/cloud/cloud-init.disabled after first boot and cloud-init won't do anything anymore15:46
blackboxswper http://cloudinit.readthedocs.io/en/latest/topics/boot.html#generator15:49
rharperapollo13: also manual_cache_clean: true  would work as well;  https://git.launchpad.net/cloud-init/tree/doc/examples/cloud-config.txt#n45015:59
blackboxswsmoser: comments on https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34294817:06
blackboxswrharper: I'll pull together a quick patch adding ntp:config key validation and post it17:10
rharperthx17:13
smoserblackboxsw: https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/342948 updated.19:18
dpb1ntp?19:18
smoseron that now.19:19
blackboxswrharper: smoser my final patch suggestion ntp  validation http://paste.ubuntu.com/p/dcKcYrM5ty/20:14
smoseri had just posted some coments there.20:15
=== natorious_ is now known as natorious
=== powersj_ is now known as powersj
=== voja_ is now known as voja
=== holser___ is now known as holser_
=== aimeeu__ is now known as aimeeu
smoserrharper: i will check back in later. i have to go now.20:32
smoserbut your issues with util.read_file_or_url20:32
smoseris that it was just busted.20:32
smoserit is supposed to return bytes in .contents20:32
smoserand str() should give you text on that thing.20:33
blackboxswhttps://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/342948 merged20:33
smoseryou could just as well use load_file sinc eyou'rre loading a file in all cases20:36
smoserhttp://paste.ubuntu.com/p/fHSjws2hR9/20:36
smoserthat set of changes works correclty, and uses the response of read_file_or_url "correctly" such that it works witih a url or a file.20:37
blackboxswaddressed review comments on https://code.launchpad.net/~chad.smith/cloud-init/+git/cloud-init/+merge/34276120:51
blackboxswchanged description20:51
rharpersmoser: my issue was that in tox -e python2.7 without my code changes, jinja blows up, not the unittests;21:14
rharperjinja2 's render_template expects decoded str (ie, not utf-8); but it does load_file() on the template (chrony) and gets back utf-8 chars; those have to be decoded before you can call jinja.render_template()21:15
rharperonce we decode the contents before rendering, the next issue was python2.7 calling str.decode() fails because the default encoding for python2.7 wasn't UTF-8;21:16
rharperthat's my analysis;21:16
rharperI'm working on switching to attribute; I like that better than the calling in init; let's see if that makes it easier21:17
smosersomething is fishy there still21:51
rharpersmoser: yes, the simple recreate is the test using the "real' templates in test_handle_ntp*.py;  if you run that one under py2.7 and remove the util.decode_text() calls, you'll see the jinja error22:24
rharperblackboxsw: thanks for the schema update; pulling that in22:24
rharpersmoser:  I'm just about ready to push an update switch to property for the preferred_ntp_clients; that works quite well and avoids mocking in non-ntp related test cases that use distro objects22:25
blackboxswnp rharper22:25
rharperok, i've pushed, I've not squashed yet but will do so before we land22:26
blackboxswlander squashes so you don't have to22:46
rharperblackboxsw: interesting22:54
* rharper likes to squash 22:54

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