- move regex out of loop and compress to two lines
- keep list comprehension to filter non route entries from regex search
- convert match into dictionary in one line
- use ternary operator to append matched route when found
- network_config is not needed in _assert_static_routes
- no longer break out network_config to pass to static_routes
- add an else clause to assert_static_routes to make sure we don't
have rendered static routes file when we shouldnt
Cloud-init network-config V1 format allows configuration of "global"
static routes which are not directly associated with any interface
in particular. These routes were not rendered under sysconfig which
generally prefers routes to be part of an interface subnet configuration.
If the configuration includes global routes, sysconfig will now render
these static routes to /etc/sysconfig/static-routes file with the 'any'
parameter indicating it will be active for any network interface.
This change does not affect existing subnet routes which continue to
be rendered into /etc/sysconfig/network-scripts/route-$iface and
route6-$iface as needed.
FreeBSD: resizefs module now able to handle zfs/zpool.
Previously there was no support at all for zfs file system. With this
change it is now possible to use the resizefs module to grow a zpool to
its maximum partition size on FreeBSD.
This adds a specific IBM Cloud datasource.
IBM Cloud is identified by:
a.) running on xen
b.) one of a LABEL=METADATA disk or a LABEL=config-2 disk with
UUID=9796-932E
The datasource contains its own config-drive reader that reads
only the currently supported portion of config-drive needed for
ibm cloud.
During the provisioning boot, cloud-init is disabled.
See the docstring in DataSourceIBMCloud.py for more more information.
tests: remove jsonschema from xenial tox environment.
Ubuntu 16.04 (xenial) does not have jsonschema installed by default. As
it is listed in requirements, the tox environment will always have it
installed.
Add the helper tools/pipremove that removes pip packages. Then use that
to remove jsonschema without noise of always running and ignoring a
'pip uninstall jsonschema'.
tests: Fix newly added schema unit tests to skip if no jsonschema.
The recently added snap and ubuntu_advantage modules had unit tests
that exercised jsonschema. Those throw error if jsonschema is
not present. Fix to skip in that scenario.