OsinfoInstallConfig

OsinfoInstallConfig — OS install configuration

Functions

OsinfoInstallConfig * osinfo_install_config_new ()
void osinfo_install_config_set_hardware_arch ()
const gchar * osinfo_install_config_get_hardware_arch ()
void osinfo_install_config_set_l10n_keyboard ()
const gchar * osinfo_install_config_get_l10n_keyboard ()
void osinfo_install_config_set_l10n_language ()
const gchar * osinfo_install_config_get_l10n_language ()
void osinfo_install_config_set_l10n_timezone ()
const gchar * osinfo_install_config_get_l10n_timezone ()
void osinfo_install_config_set_admin_password ()
const gchar * osinfo_install_config_get_admin_password ()
void osinfo_install_config_set_user_login ()
const gchar * osinfo_install_config_get_user_login ()
void osinfo_install_config_set_user_password ()
const gchar * osinfo_install_config_get_user_password ()
void osinfo_install_config_set_user_realname ()
const gchar * osinfo_install_config_get_user_realname ()
void osinfo_install_config_set_user_autologin ()
gboolean osinfo_install_config_get_user_autologin ()
void osinfo_install_config_set_user_administrator ()
gboolean osinfo_install_config_get_user_administrator ()
void osinfo_install_config_set_reg_login ()
const gchar * osinfo_install_config_get_reg_login ()
void osinfo_install_config_set_reg_password ()
const gchar * osinfo_install_config_get_reg_password ()
void osinfo_install_config_set_reg_product_key ()
const gchar * osinfo_install_config_get_reg_product_key ()
void osinfo_install_config_set_hostname ()
const gchar * osinfo_install_config_get_hostname ()
void osinfo_install_config_set_target_disk ()
const gchar * osinfo_install_config_get_target_disk ()
void osinfo_install_config_set_script_disk ()
const gchar * osinfo_install_config_get_script_disk ()
void osinfo_install_config_set_avatar_location ()
const gchar * osinfo_install_config_get_avatar_location ()
void osinfo_install_config_set_avatar_disk ()
const gchar * osinfo_install_config_get_avatar_disk ()
void osinfo_install_config_set_pre_install_drivers_disk ()
const gchar * osinfo_install_config_get_pre_install_drivers_disk ()
void osinfo_install_config_set_pre_install_drivers_location ()
const gchar * osinfo_install_config_get_pre_install_drivers_location ()
void osinfo_install_config_set_post_install_drivers_disk ()
const gchar * osinfo_install_config_get_post_install_drivers_disk ()
void osinfo_install_config_set_post_install_drivers_location ()
const gchar * osinfo_install_config_get_post_install_drivers_location ()
void osinfo_install_config_set_driver_signing ()
gboolean osinfo_install_config_get_driver_signing ()

Types and Values

Object Hierarchy

    GObject
    ╰── OsinfoEntity
        ╰── OsinfoInstallConfig

Description

OsinfoInstallConfig is an object for representing OS install configuration data. It is used to generate an automated installation script

Functions

osinfo_install_config_new ()

OsinfoInstallConfig *
osinfo_install_config_new (const gchar *id);

Construct a new install configuration with default values for language, keyboard, timezone and admin password. The default values are to use an 'en_US' language and keyboard, and an 'America/New_York' timezone. The admin password is set to a random 8 character password.

Parameters

id

the unique identifier

 

Returns

an install configuration with default values.

[transfer full]


osinfo_install_config_set_hardware_arch ()

void
osinfo_install_config_set_hardware_arch
                               (OsinfoInstallConfig *config,
                                const gchar *arch);

osinfo_install_config_get_hardware_arch ()

const gchar *
osinfo_install_config_get_hardware_arch
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_l10n_keyboard ()

void
osinfo_install_config_set_l10n_keyboard
                               (OsinfoInstallConfig *config,
                                const gchar *keyboard);

Sets the OSINFO_INSTALL_CONFIG_PROP_L10N_KEYBOARD parameter.

The expected format of this string is the same as osinfo_install_config_set_l10n_language function's 'language' parameter.

Parameters

config

the install config

 

keyboard

the keyboard

 

osinfo_install_config_get_l10n_keyboard ()

const gchar *
osinfo_install_config_get_l10n_keyboard
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_l10n_language ()

void
osinfo_install_config_set_l10n_language
                               (OsinfoInstallConfig *config,
                                const gchar *language);

Sets the OSINFO_INSTALL_CONFIG_PROP_L10N_LANGUAGE parameter.

The expected format of this string is the gettext locale names standard:

https://www.gnu.org/savannah-checkouts/gnu/gettext/manual/html_node/Locale-Names.html

Encoding and variant are (at least for now) not supported. For example, 'pt_BR' is accepted is accepted as the language codes for Brazilian Portuguese but 'pt_BR.utf8' is not.

Parameters

config

the install config

 

language

the language

 

osinfo_install_config_get_l10n_language ()

const gchar *
osinfo_install_config_get_l10n_language
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_l10n_timezone ()

void
osinfo_install_config_set_l10n_timezone
                               (OsinfoInstallConfig *config,
                                const gchar *timezone);

osinfo_install_config_get_l10n_timezone ()

const gchar *
osinfo_install_config_get_l10n_timezone
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_admin_password ()

void
osinfo_install_config_set_admin_password
                               (OsinfoInstallConfig *config,
                                const gchar *password);

osinfo_install_config_get_admin_password ()

const gchar *
osinfo_install_config_get_admin_password
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_user_login ()

void
osinfo_install_config_set_user_login (OsinfoInstallConfig *config,
                                      const gchar *username);

osinfo_install_config_get_user_login ()

const gchar *
osinfo_install_config_get_user_login (OsinfoInstallConfig *config);

osinfo_install_config_set_user_password ()

void
osinfo_install_config_set_user_password
                               (OsinfoInstallConfig *config,
                                const gchar *password);

osinfo_install_config_get_user_password ()

const gchar *
osinfo_install_config_get_user_password
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_user_realname ()

void
osinfo_install_config_set_user_realname
                               (OsinfoInstallConfig *config,
                                const gchar *name);

osinfo_install_config_get_user_realname ()

const gchar *
osinfo_install_config_get_user_realname
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_user_autologin ()

void
osinfo_install_config_set_user_autologin
                               (OsinfoInstallConfig *config,
                                gboolean autologin);

osinfo_install_config_get_user_autologin ()

gboolean
osinfo_install_config_get_user_autologin
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_user_administrator ()

void
osinfo_install_config_set_user_administrator
                               (OsinfoInstallConfig *config,
                                gboolean admin);

osinfo_install_config_get_user_administrator ()

gboolean
osinfo_install_config_get_user_administrator
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_reg_login ()

void
osinfo_install_config_set_reg_login (OsinfoInstallConfig *config,
                                     const gchar *name);

osinfo_install_config_get_reg_login ()

const gchar *
osinfo_install_config_get_reg_login (OsinfoInstallConfig *config);

osinfo_install_config_set_reg_password ()

void
osinfo_install_config_set_reg_password
                               (OsinfoInstallConfig *config,
                                const gchar *password);

osinfo_install_config_get_reg_password ()

const gchar *
osinfo_install_config_get_reg_password
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_reg_product_key ()

void
osinfo_install_config_set_reg_product_key
                               (OsinfoInstallConfig *config,
                                const gchar *key);

osinfo_install_config_get_reg_product_key ()

const gchar *
osinfo_install_config_get_reg_product_key
                               (OsinfoInstallConfig *config);

osinfo_install_config_set_hostname ()

void
osinfo_install_config_set_hostname (OsinfoInstallConfig *config,
                                    const gchar *hostname);

Sets the OSINFO_INSTALL_CONFIG_PROP_HOSTNAME parameter.

Note that some operating systems have restrictions on maximum number of, and allowed characters in hostname (or its equivalent) so it is highly recommended that you keep the actual hostname less than or equal to 15 characters long and make sure that it does not contain any characters other than ASCII alphanumeric and '-'. Otherwise unattended installation might fail.

Parameters

config

the install config

 

hostname

the desired hostname

 

osinfo_install_config_get_hostname ()

const gchar *
osinfo_install_config_get_hostname (OsinfoInstallConfig *config);

osinfo_install_config_set_target_disk ()

void
osinfo_install_config_set_target_disk (OsinfoInstallConfig *config,
                                       const gchar *disk);

Sets the OSINFO_INSTALL_CONFIG_PROP_TARGET_DISK parameter.

Note that the format of this string is dependent on the installer script config is going to be used with. You can use osinfo_install_script_get_path_format() to find out which format does the script expects this string to be in. In case of OSINFO_PATH_FORMAT_UNIX unix device node names are expected, e.g "/dev/fd0". In case of OSINFO_PATH_FORMAT_DOS drive letters are expected, e.g "A".

Parameters

config

the install config

 

disk

the target disk

 

osinfo_install_config_get_target_disk ()

const gchar *
osinfo_install_config_get_target_disk (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The value of OSINFO_INSTALL_CONFIG_PROP_TARGET_DISK parameter, or NULL.


osinfo_install_config_set_script_disk ()

void
osinfo_install_config_set_script_disk (OsinfoInstallConfig *config,
                                       const gchar *disk);

Sets the OSINFO_INSTALL_CONFIG_PROP_SCRIPT_DISK parameter.

Please read documentation on osinfo_install_config_set_target_disk() for explanation on the format of disk string.

Parameters

config

the install config

 

disk

the disk

 

osinfo_install_config_get_script_disk ()

const gchar *
osinfo_install_config_get_script_disk (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The value of OSINFO_INSTALL_CONFIG_PROP_SCRIPT_DISK parameter, or NULL.


osinfo_install_config_set_avatar_location ()

void
osinfo_install_config_set_avatar_location
                               (OsinfoInstallConfig *config,
                                const gchar *location);

Sets the OSINFO_INSTALL_CONFIG_PROP_AVATAR_LOCATION parameter.

Note that the format of this string is dependent on the installer script config is going to be used with. You can use osinfo_install_script_get_path_format() to find out which format does the script expects this string to be in.

Also note that in case of OSINFO_PATH_FORMAT_DOS, the drive/disk letter and the leading ':' must not be included in the path.

Parameters

config

the install config

 

location

new location

 

osinfo_install_config_get_avatar_location ()

const gchar *
osinfo_install_config_get_avatar_location
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The value of OSINFO_INSTALL_CONFIG_PROP_AVATAR_LOCATION parameter, or NULL.


osinfo_install_config_set_avatar_disk ()

void
osinfo_install_config_set_avatar_disk (OsinfoInstallConfig *config,
                                       const gchar *disk);

Sets the OSINFO_INSTALL_CONFIG_PROP_AVATAR_DISK parameter.

Please read documentation on osinfo_install_config_set_target_disk() for explanation on the format of disk string.

Parameters

config

the install config

 

disk

the avatar disk

 

osinfo_install_config_get_avatar_disk ()

const gchar *
osinfo_install_config_get_avatar_disk (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The value of OSINFO_INSTALL_CONFIG_PROP_AVATAR_DISK parameter, or NULL.


osinfo_install_config_set_pre_install_drivers_disk ()

void
osinfo_install_config_set_pre_install_drivers_disk
                               (OsinfoInstallConfig *config,
                                const gchar *disk);

Specify the disk on which drivers to be installed at the very beginning of installation, are available. This is usually needed for devices for which the OS in question does not have out of the box support for and devices are required/prefered to be available during actual installation.

Please read documentation on osinfo_install_config_set_target_disk() for explanation on the format of disk string.

NOTE: Not every install script supports pre-installation of drivers. Use osinfo_install_script_get_can_pre_install_drivers() to find out if an installer script supports it.

NOTE: Microsoft Windows XP requires pre-installation driver files to be present in the script disk under the toplevel directory.

Parameters

config

the install config

 

disk

the disk

 

osinfo_install_config_get_pre_install_drivers_disk ()

const gchar *
osinfo_install_config_get_pre_install_drivers_disk
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The disk on which pre-installation drivers are located, or NULL if its not set using osinfo_install_config_set_pre_install_drivers_disk().


osinfo_install_config_set_pre_install_drivers_location ()

void
osinfo_install_config_set_pre_install_drivers_location
                               (OsinfoInstallConfig *config,
                                const gchar *location);

Specify the location on which drivers to be installed at the very beginning of installation, are available. Please read documentation on osinfo_install_config_set_pre_install_drivers_disk() for more information about pre-installation of drivers.

Please read documentation on osinfo_install_config_set_avatar_location() for explanation on the format of location string.

Parameters

config

the install config

 

location

the location

 

osinfo_install_config_get_pre_install_drivers_location ()

const gchar *
osinfo_install_config_get_pre_install_drivers_location
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The location on which pre-installation drivers are located, or NULL if its not set using osinfo_install_config_set_pre_install_drivers_location().


osinfo_install_config_set_post_install_drivers_disk ()

void
osinfo_install_config_set_post_install_drivers_disk
                               (OsinfoInstallConfig *config,
                                const gchar *disk);

Specify the disk on which drivers to be installed at the end of installation, are available.

Please read documentation on osinfo_install_config_set_target_disk() for explanation on the format of disk string.

NOTE: Not every install script supports post-installation of drivers. Use osinfo_install_script_get_can_post_install_drivers() to find out if an install script supports it.

Parameters

config

the install config

 

disk

the target disk

 

osinfo_install_config_get_post_install_drivers_disk ()

const gchar *
osinfo_install_config_get_post_install_drivers_disk
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The disk on which post-installation drivers are located, or NULL if its not set using osinfo_install_config_set_post_install_drivers_disk().


osinfo_install_config_set_post_install_drivers_location ()

void
osinfo_install_config_set_post_install_drivers_location
                               (OsinfoInstallConfig *config,
                                const gchar *location);

Specify the disk on which drivers to be installed at the end of installation, are available.

Please read documentation on osinfo_install_config_set_avatar_location() for explanation on the format of location string.

NOTE: Not every install script supports post-installation of drivers. Use osinfo_install_script_get_can_post_install_drivers() to find out if an install script supports it.

Parameters

config

the install config

 

location

the location of avatar

 

osinfo_install_config_get_post_install_drivers_location ()

const gchar *
osinfo_install_config_get_post_install_drivers_location
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

The disk on which post-installation drivers are located, or NULL if its not set using osinfo_install_config_set_post_install_drivers_location().


osinfo_install_config_set_driver_signing ()

void
osinfo_install_config_set_driver_signing
                               (OsinfoInstallConfig *config,
                                gboolean signing);

If a script requires drivers to be signed, this function can be used to disable that security feature. WARNING: Disabling driver signing may very well mean disabling it permanently.

Parameters

config

the install config

 

signing

boolean value

 

osinfo_install_config_get_driver_signing ()

gboolean
osinfo_install_config_get_driver_signing
                               (OsinfoInstallConfig *config);

Parameters

config

the install config

 

Returns

TRUE if driver signing is currently enabled, FALSE otherwise, see osinfo_install_config_set_driver_signing() for more details about driver signing.

Types and Values

OSINFO_INSTALL_CONFIG_PROP_HARDWARE_ARCH

#define OSINFO_INSTALL_CONFIG_PROP_HARDWARE_ARCH  "hardware-arch"

OSINFO_INSTALL_CONFIG_PROP_L10N_TIMEZONE

#define OSINFO_INSTALL_CONFIG_PROP_L10N_TIMEZONE  "l10n-timezone"

OSINFO_INSTALL_CONFIG_PROP_L10N_LANGUAGE

#define OSINFO_INSTALL_CONFIG_PROP_L10N_LANGUAGE  "l10n-language"

OSINFO_INSTALL_CONFIG_PROP_L10N_KEYBOARD

#define OSINFO_INSTALL_CONFIG_PROP_L10N_KEYBOARD  "l10n-keyboard"

OSINFO_INSTALL_CONFIG_PROP_ADMIN_PASSWORD

#define OSINFO_INSTALL_CONFIG_PROP_ADMIN_PASSWORD "admin-password"

OSINFO_INSTALL_CONFIG_PROP_USER_PASSWORD

#define OSINFO_INSTALL_CONFIG_PROP_USER_PASSWORD  "user-password"

OSINFO_INSTALL_CONFIG_PROP_USER_LOGIN

#define OSINFO_INSTALL_CONFIG_PROP_USER_LOGIN     "user-login"

OSINFO_INSTALL_CONFIG_PROP_USER_REALNAME

#define OSINFO_INSTALL_CONFIG_PROP_USER_REALNAME  "user-realname"

OSINFO_INSTALL_CONFIG_PROP_USER_AUTOLOGIN

#define OSINFO_INSTALL_CONFIG_PROP_USER_AUTOLOGIN "user-autologin"

OSINFO_INSTALL_CONFIG_PROP_USER_ADMIN

#define OSINFO_INSTALL_CONFIG_PROP_USER_ADMIN     "user-admin"

OSINFO_INSTALL_CONFIG_PROP_REG_LOGIN

#define OSINFO_INSTALL_CONFIG_PROP_REG_LOGIN      "reg-login"

OSINFO_INSTALL_CONFIG_PROP_REG_PASSWORD

#define OSINFO_INSTALL_CONFIG_PROP_REG_PASSWORD   "reg-password"

OSINFO_INSTALL_CONFIG_PROP_REG_PRODUCTKEY

#define OSINFO_INSTALL_CONFIG_PROP_REG_PRODUCTKEY "reg-product-key"

OSINFO_INSTALL_CONFIG_PROP_HOSTNAME

#define OSINFO_INSTALL_CONFIG_PROP_HOSTNAME    "hostname"

OSINFO_INSTALL_CONFIG_PROP_TARGET_DISK

#define OSINFO_INSTALL_CONFIG_PROP_TARGET_DISK "target-disk"

OSINFO_INSTALL_CONFIG_PROP_SCRIPT_DISK

#define OSINFO_INSTALL_CONFIG_PROP_SCRIPT_DISK "script-disk"

OSINFO_INSTALL_CONFIG_PROP_AVATAR_LOCATION

#define OSINFO_INSTALL_CONFIG_PROP_AVATAR_LOCATION "avatar-location"

OSINFO_INSTALL_CONFIG_PROP_AVATAR_DISK

#define OSINFO_INSTALL_CONFIG_PROP_AVATAR_DISK     "avatar-disk"

OSINFO_INSTALL_CONFIG_PROP_PRE_INSTALL_DRIVERS_DISK

#define OSINFO_INSTALL_CONFIG_PROP_PRE_INSTALL_DRIVERS_DISK "pre-install-drivers-disk"

OSINFO_INSTALL_CONFIG_PROP_PRE_INSTALL_DRIVERS_LOCATION

#define OSINFO_INSTALL_CONFIG_PROP_PRE_INSTALL_DRIVERS_LOCATION "pre-install-drivers-location"

OSINFO_INSTALL_CONFIG_PROP_POST_INSTALL_DRIVERS_DISK

#define OSINFO_INSTALL_CONFIG_PROP_POST_INSTALL_DRIVERS_DISK "post-install-drivers-disk"

OSINFO_INSTALL_CONFIG_PROP_POST_INSTALL_DRIVERS_LOCATION

#define OSINFO_INSTALL_CONFIG_PROP_POST_INSTALL_DRIVERS_LOCATION "post-install-drivers-location"

OSINFO_INSTALL_CONFIG_PROP_DRIVER_SIGNING

#define OSINFO_INSTALL_CONFIG_PROP_DRIVER_SIGNING "driver-signing"

See Also

OsinfoInstallScript