Puppet Class: ironic::drivers::pxe
- Defined in:
- manifests/drivers/pxe.pp
Overview
Configure the PXE driver in Ironic
Parameters
- kernel_append_params
-
(optional) Additional append parameters for baremetal PXE boot. Should be valid pxe parameters Defaults to $::os_service_default.
- pxe_bootfile_name
-
(optional) Bootfile DHCP parameter. If not set, its value is detected. Defaults to $::os_service_default.
- pxe_config_template
-
(optional) Template file for PXE configuration. If set, should be an valid template file. Otherwise, its value is detected. Defaults to $::os_service_default.
- ipxe_bootfile_name
-
(optional) Bootfile DHCP parameter when the ipxe boot interface is set for a baremetal node. If not set, its value is detected. Defaults to $::os_service_default.
- ipxe_config_template
-
(optional) Template file for PXE configuration with the iPXE boot interface. If set, should be an valid template file. Otherwise, its value is detected. Defaults to $::os_service_default.
- tftp_server
-
(optional) IP address of Ironic compute node’s tftp server. Should be an valid IP address Defaults to $::os_service_default.
- tftp_root
-
(optional) Ironic compute node’s tftp root path. Should be an valid path Defaults to $::os_service_default.
- images_path
-
(optional) Directory where images are stored on disk. Should be an valid directory Defaults to $::os_service_default.
- tftp_master_path
-
(optional) Directory where master tftp images are stored on disk. Should be an valid directory Defaults to $::os_service_default.
- instance_master_path
-
(optional) Directory where master tftp images are stored on disk. Should be an valid directory Defaults to $::os_service_default.
- uefi_pxe_bootfile_name
-
(optional) Bootfile DHCP parameter for UEFI boot mode. Defaults to $::os_service_default.
- uefi_pxe_config_template
-
(optional) Template file for PXE configuration for UEFI boot loader. Defaults to $::os_service_default.
- uefi_ipxe_bootfile_name
-
(optional) Bootfile DHCP parameter for UEFI boot mode for the ipxe boot interface. No separate configuration template is required when using ipxe. Defaults to snponly.efi, which supports UEFI firmware with network enablement, which is a standard feature in UEFI.
- ipxe_timeout
-
(optional) ipxe timeout in second. Should be an valid integer Defaults to $::os_service_default.
- enable_ppc64le
-
(optional) Boolean value to dtermine if ppc64le support should be enabled Defaults to false (no ppc64le support)
- boot_retry_timeout
-
(optional) Timeout (in seconds) after which PXE boot should be retried. Defaults to $::os_service_default.
- boot_retry_check_interval
-
(optional) How often (in seconds) to check for PXE boot status. Defaults to $::os_service_default.
- dir_permission
-
(optional) THe permission that will be applied to the TFTP folders upon creation. Defaults to $::os_service_default.
- file_permission
-
(optional) The permission which is used on files created as part of configuration and setup of file assets for PXE based operations. Defaults to $::os_service_default.
- loader_file_paths
-
(optional) Dictionary describing the bootloaders to load into conductor PXE/iXPE boot folders values from the host operating system. Defaults to $::os_service_default.
DEPRECATED PARAMETERS
- ipxe_enabled
-
DEPRECATED: This option is no longer used as support for the option was deprecated during Ironic’s Stein development cycle and removed during Ironic’s Train development cycle. If this setting is populated, a warning will be indicated.
- ip_version
-
DEPRECATED: (optional) The IP version that will be used for PXE booting. Ironic presently attempts both IPv4 and IPv6, this option is effectively ignored by ironic, and should anticipate being removed in a future release. Defaults to $::os_service_default.
- pxe_append_params
-
(optional) Additional append parameters for baremetal PXE boot. Should be valid pxe parameters Defaults to undef.
140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 |
# File 'manifests/drivers/pxe.pp', line 140
class ironic::drivers::pxe (
$kernel_append_params = $::os_service_default,
$pxe_bootfile_name = $::os_service_default,
$pxe_config_template = $::os_service_default,
$ipxe_bootfile_name = $::os_service_default,
$ipxe_config_template = $::os_service_default,
$tftp_server = $::os_service_default,
$tftp_root = $::os_service_default,
$images_path = $::os_service_default,
$tftp_master_path = $::os_service_default,
$instance_master_path = $::os_service_default,
$uefi_pxe_bootfile_name = $::os_service_default,
$uefi_pxe_config_template = $::os_service_default,
$uefi_ipxe_bootfile_name = 'snponly.efi',
$ipxe_timeout = $::os_service_default,
$enable_ppc64le = false,
$boot_retry_timeout = $::os_service_default,
$boot_retry_check_interval = $::os_service_default,
$dir_permission = $::os_service_default,
$file_permission = $::os_service_default,
$loader_file_paths = $::os_service_default,
# DEPRECATED PARAMETERS
$ipxe_enabled = undef,
$ip_version = undef,
$pxe_append_params = undef,
) {
include ironic::deps
include ironic::pxe::common
$tftp_root_real = pick($::ironic::pxe::common::tftp_root, $tftp_root)
$ipxe_timeout_real = pick($::ironic::pxe::common::ipxe_timeout, $ipxe_timeout)
if $ipxe_enabled != undef {
warning('The ironic::drivers::pxe::ipxe_enabled parameter is deprecated and has no effect.')
}
if $ip_version != undef {
warning('The ironic::drivers::pxe:ip_version parameter is deprecated and will be removed in the future.')
}
$ip_version_real = pick($ip_version, $::os_service_default)
if $pxe_append_params != undef {
warning('The ironic::drivers::pxe::pxe_append_params parameter is deprecated. \
Use the kernel_append_params parameter instead')
}
$kernel_append_params_real = pick($pxe_append_params, kernel_append_params)
ironic_config {
'pxe/pxe_append_params': ensure => absent
}
# Configure ironic.conf
ironic_config {
'pxe/kernel_append_params': value => $kernel_append_params;
'pxe/pxe_bootfile_name': value => $pxe_bootfile_name;
'pxe/pxe_config_template': value => $pxe_config_template;
'pxe/ipxe_bootfile_name': value => $ipxe_bootfile_name;
'pxe/ipxe_config_template': value => $ipxe_config_template;
'pxe/tftp_server': value => $tftp_server;
'pxe/tftp_root': value => $tftp_root_real;
'pxe/images_path': value => $images_path;
'pxe/tftp_master_path': value => $tftp_master_path;
'pxe/instance_master_path': value => $instance_master_path;
'pxe/uefi_pxe_bootfile_name': value => $uefi_pxe_bootfile_name;
'pxe/uefi_pxe_config_template': value => $uefi_pxe_config_template;
'pxe/uefi_ipxe_bootfile_name': value => $uefi_ipxe_bootfile_name;
'pxe/ipxe_timeout': value => $ipxe_timeout_real;
'pxe/boot_retry_timeout': value => $boot_retry_timeout;
'pxe/boot_retry_check_interval': value => $boot_retry_check_interval;
'pxe/dir_permission': value => $dir_permission;
'pxe/file_permission': value => $file_permission;
'pxe/loader_file_paths': value => join(any2array($loader_file_paths), ',');
'pxe/ipxe_enabled': ensure => absent;
'pxe/ip_version': value => $ip_version_real;
}
if $enable_ppc64le {
# FXIME(tonyb): As these are really hash values it would beter to model
# them that way. We can do that later, probably when we add another
# architecture
ironic_config {
# NOTE(tonyb): This first value shouldn't be needed but seems to be?
# NOTE(TheJulia): Likely not needed as this just points to the default,
# and when the explicit pxe driver is used everything should fall to
# it but in the interest of minimizing impact, the output result
# is preserved as we now just allow the default for normal template
# operation to be used.
'pxe/pxe_config_template_by_arch': value => 'ppc64le:$pybasedir/drivers/modules/pxe_config.template';
'pxe/pxe_bootfile_name_by_arch': value => 'ppc64le:config';
}
}
}
|