[Libosinfo] [PATCH 2/4] install-scripts: Add requires-initrd-injection API
Daniel P. Berrange
berrange at redhat.com
Mon Dec 2 09:45:01 UTC 2013
On Sun, Dec 01, 2013 at 04:09:35AM +0100, Fabiano Fidêncio wrote:
> Some OSes, to provide unattended installation support, require the
> configuration file injection on its initrd.
> ---
> data/schemas/libosinfo.rng | 5 +++++
> osinfo/libosinfo.syms | 2 ++
> osinfo/osinfo_install_script.c | 16 ++++++++++++++++
> osinfo/osinfo_install_script.h | 3 +++
> osinfo/osinfo_loader.c | 1 +
> 5 files changed, 27 insertions(+)
> diff --git a/osinfo/osinfo_install_script.c b/osinfo/osinfo_install_script.c
> index 7444c8d..81ab3c8 100644
> --- a/osinfo/osinfo_install_script.c
> +++ b/osinfo/osinfo_install_script.c
> @@ -1309,6 +1309,22 @@ int osinfo_install_script_get_post_install_drivers_signing_req(OsinfoInstallScri
> OSINFO_DEVICE_DRIVER_SIGNING_REQ_NONE);
> }
>
> +/**
> + * osinfo_install_script_get_requires_initrd_injection:
> + * @script: the install script
> + *
> + * Whether install script should be injected into the initrd file to be used
> + * in the installion. This is needed for Debian/Ubuntu automated installation.
> + *
> + * Returns: TRUE if install script requires initrd injection, FALSE otherwise.
> + */
> +gboolean osinfo_install_script_get_requires_initrd_injection(OsinfoInstallScript *script)
> +{
> + return osinfo_entity_get_param_value_boolean
> + (OSINFO_ENTITY(script),
> + OSINFO_INSTALL_SCRIPT_PROP_REQUIRES_INITRD_INJECTION);
> +}
And other OS require injection into the CDROM media ? Or creation of a
standalone disk, or standalone floppy, or standalone cdrom ?
IOW, can we generalize this somehow. We have a set of device types that
can hold the data so it seems we need an API which returns a list of
valid approaches/devices for providing the install script files.
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
More information about the Libosinfo
mailing list