<feed xmlns='http://www.w3.org/2005/Atom'>
<title>vyos-cloud-init.git/templates/chrony.conf.ubuntu.tmpl, branch rolling</title>
<subtitle> (mirror of https://github.com/vyos/vyos-cloud-init.git)
</subtitle>
<id>https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=rolling</id>
<link rel='self' href='https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=rolling'/>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/'/>
<updated>2018-04-12T21:51:07+00:00</updated>
<entry>
<title>renderer: support unicode in render_from_file.</title>
<updated>2018-04-12T21:51:07+00:00</updated>
<author>
<name>Scott Moser</name>
<email>smoser@ubuntu.com</email>
</author>
<published>2018-04-12T21:51:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=4b86ab9a25b512420ecfe98953a3f3a6e4b4bba1'/>
<id>urn:sha1:4b86ab9a25b512420ecfe98953a3f3a6e4b4bba1</id>
<content type='text'>
If a file passed to render_from_file had non-ascii text then
jinja in python2 would decode as ascii, which would cause
UnicodeDecodeError.  This issue can be re-created in python2
with just:
 'can\xe2\x80\x99t'.decode()

The solution here is to explicitly pass in unicode supporting
type (py3 str, py2 unicode).  Those are six.text_type.
Then jinja does not try to decode.

The reason we hit this is that load_file calls decode_binary.
decode_binary believes it has no work to do if it got a six.string_types.
  isinstance('can\xe2\x80\x99t', six.string_types) == True
So it returns the original string which will blow up for jinja.

Our fix here then is to load the file in binary mode and explicitly
decode it to utf-8.  Then in python2 we'll have a unicode type
and in python3 we'll have a string type.
</content>
</entry>
<entry>
<title>Implement ntp client spec with auto support for distro selection</title>
<updated>2018-04-12T19:32:25+00:00</updated>
<author>
<name>Ryan Harper</name>
<email>ryan.harper@canonical.com</email>
</author>
<published>2018-04-12T19:32:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=c6dff581a9c253170d5e3f12fb83d16a8dec8257'/>
<id>urn:sha1:c6dff581a9c253170d5e3f12fb83d16a8dec8257</id>
<content type='text'>
Add a base NTP client configuration dictionary and allow Distro
specific changes to be merged.  Add a select client function which
implements logic to preferr installed clients over clients which
need to be installed.  Also allow distributions to override the
cloud-init defaults.

LP: #1749722
</content>
</entry>
</feed>
