Last commit made on 2017-05-13
Get this branch:
git clone -b typeerror https://git.launchpad.net/~xnox/cloud-init
Only Dimitri John Ledkov can upload to this branch. If you are Dimitri John Ledkov please log in for upload directions.

Branch merges

Branch information


Recent commits

e2503df... by Dimitri John Ledkov on 2017-05-13

netplan: fix render_network_state arguments positions

tools/net-convert fails to output netplan config, because the
positional arguments of render_network_state are the wrong way around
for that function w.r.t. other renders.

cloudinit/net/netplan.py: def render_network_state(self, target, network_state):


cloudinit/net/eni.py: def render_network_state(self, network_state, target=None):
cloudinit/net/renderer.py: def render_network_state(self, network_state, target=None):
cloudinit/net/sysconfig.py: def render_network_state(self, network_state, target=None):

dd03bb4... by Chad Smith on 2017-05-10

sysconfig: Raise ValueError when multiple default gateways are present.

Fixed setting Route.has_set_default_ipv6 or *_ipv4 to track whether a
route already has a default gateway defined. The code was setting
Route.has_set_default which wasn't checked when raising "duplicate
gateway" ValueErrors. Added unit tests to exercise this expected raised
ValueError. Also moved is_ipv6 = subnet.get('ipv6') logic out of a for
loop because we don't need to recalculate the same value every route

LP: #1687485

0a71d5a... by Hongjiang Zhang on 2017-01-13

FreeBSD: improvements and fixes for use on Azure

This patch targets to make FreeBSD 10.3 or 11 work on Azure. The
modifications abide by the rule of:
  * making as less modification as possible
  * delegate to the distro or datasource where possible.

The main modifications are:
 1. network configuration improvements, and movement into distro path.
 2. Fix setting of password.
    Password setting through "pw" can only work through pipe.
 3. Add 'root:wheel' to syslog_fix_perms field.
 4. Support resizing default file system (ufs)
 5. copy cloud.cfg for freebsd to /etc/cloud/cloud.cfg rather than
 6. Azure specific changes:
    a. When reading the azure endpoint, search in a different path
       and read a different option name (option-245 vs. unknown-245).
        so, the lease file path should be generated according to platform.
    b. adjust the handling of ephemeral mounts for ufs filesystem and
       for finding the ephemeral device.
    c. fix mounting of cdrom

LP: #1636345

370a04e... by Scott Moser on 2017-02-11

Add unit tests for ds-identify, fix Ec2 bug found.

This adds several unit tests for ds-identify, and fixes a bug
in Ec2 detection that I found while writing these tests.

The method of testing is to use the ds-identify code as a shell
library. The TestDsIdentify:call basically does:

  * populate a (temp) directory with files that represent what
    ds-identify would see in /sys or other locations it reads.
  * create a file '_shwrap' that replaces the 3 programs that are executed
    in ds-identify code path. It supports setting their stdout, stderr,
    and exit code.
  * set the default policies explicitly (DI_DEFAULT_POLICY) so we can
    support testing different builtins. This is necessary because the
    Ubuntu branches patch the builtin value. If we did not explicilty set
    it, then testing there would fail.
  * execute sh to source the script and call its main.

4f0f171... by Paul Meyer on 2017-05-02

fs_setup: if cmd is specified, use shell interpretation.

If 'cmd' is provided to a fs_setup entry, then cloud-init was trying
to execute the rendered string as a single name, rather than
splitting the string. The change here will pass the string to
shell for interpretation so that it is split there.

Also fix some documentation errors and warn when fs_opts or overwrite
is provided along with 'cmd'.

LP: #1687712

99faf3e... by Ryan Harper on 2017-03-30

doc: document network configuration defaults policy and formats.

Add documentation for cloud-init networking configuration formats, default
behavior, policy and other specific details about how network config is
consumed and utilized.

653fda9... by Felix Dreissig on 2017-04-29

Fix name of "uri" key in docs for "cc_apt_configure" module

The key is called "uri", not "url". This is what's used throughout the
examples and also what works in practice (verified on Ubuntu 16.10).
This also slightly improves formatting of the key names in the
related documentation.

2796dab... by Joshua Powers on 2017-04-26

tests: Enable artful

513e99e... by Scott Moser on 2017-04-24

nova-lxd: read product_name from environment, not platform.

Apparently signals were crossed when this implementation was done.
Cloud-init was reading 'platform' in the environment of pid 1, but
nova-lxd was setting 'product_name'.

The fix is being made here in cloud-init to instead read product_name.

LP: #1685810

d16632a... by Dylan Perry on 2017-04-07

Fix yum repo config where keys contain array values

ConfigObj produces configuration files that are incompatible with yum if
multiple values are listed for a configuration key. Switch to the builtin
configparser, and ConfigParser (Python 2) which correctly handles this

Add additional test case for array values in yum_repos definition

LP: #1592150