cloud-init-dev team mailing list archive
-
cloud-init-dev team
-
Mailing list archive
-
Message #06546
Re: [Merge] ~daniel-thewatkins/cloud-init/+git/cloud-init:dracut into cloud-init:master
Diff comments:
> diff --git a/cloudinit/net/cmdline.py b/cloudinit/net/cmdline.py
> index 556a10f..c05d36c 100755
> --- a/cloudinit/net/cmdline.py
> +++ b/cloudinit/net/cmdline.py
> @@ -137,6 +203,24 @@ def config_from_klibc_net_cfg(files=None, mac_addrs=None):
> return {'config': entries, 'version': 1}
>
>
> +def read_initramfs_config():
> + """
> + Return v1 network config for initramfs-configured networking (or None)
> +
> + This will consider each _INITRAMFS_CONFIG_SOURCES entry in turn, and return
> + v1 network configuration for the first one that is applicable. If none are
> + applicable, return None.
> + """
> + for src_cls in _INITRAMFS_CONFIG_SOURCES:
Yeah, good thinking. I'll refactor bits up as I find them in the dracut work. (Because, for example, the open-iscsi check _doesn't_ apply to dracut. They do use open-iscsi, but that file isn't present.)
> + cfg_source = src_cls()
> +
> + if not cfg_source.is_applicable():
> + continue
> +
> + return cfg_source.render_config()
> + return None
> +
> +
> def _decomp_gzip(blob, strict=True):
> # decompress blob. raise exception if not compressed unless strict=False.
> with io.BytesIO(blob) as iobuf:
--
https://code.launchpad.net/~daniel-thewatkins/cloud-init/+git/cloud-init/+merge/371673
Your team cloud-init commiters is requested to review the proposed merge of ~daniel-thewatkins/cloud-init/+git/cloud-init:dracut into cloud-init:master.
References