Skip to content

Commit ea94fab

Browse files
committed
feat: add ironic environment mixins
Add support for environment mixins that capture the configuration behind `ironic` for both `redfish` and `ipmi`. It is expected the users environments will depend on `stack-ironic-{redfish,ipmi}` and not `stack-ironic`.
1 parent 84ad62b commit ea94fab

File tree

18 files changed

+680
-0
lines changed

18 files changed

+680
-0
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
dependencies:
3+
- stack-ironic
Lines changed: 161 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,161 @@
1+
---
2+
###############################################################################
3+
# General configuration of inspection.
4+
5+
# Timeout of hardware inspection on baremetal compute nodes, in seconds.
6+
# Default is 1200.
7+
#inspector_inspection_timeout:
8+
9+
###############################################################################
10+
# Ironic inspector PXE configuration.
11+
12+
# List of extra kernel parameters for the inspector default PXE configuration.
13+
#inspector_extra_kernel_options:
14+
15+
# URL of Ironic Python Agent (IPA) kernel image.
16+
#inspector_ipa_kernel_upstream_url:
17+
18+
# URL of checksum of Ironic Python Agent (IPA) kernel image.
19+
#inspector_ipa_kernel_checksum_url:
20+
21+
# Algorithm of checksum of Ironic Python Agent (IPA) kernel image.
22+
#inspector_ipa_kernel_checksum_algorithm:
23+
24+
# URL of Ironic Python Agent (IPA) ramdisk image.
25+
#inspector_ipa_ramdisk_upstream_url:
26+
27+
# URL of checksum of Ironic Python Agent (IPA) ramdisk image.
28+
#inspector_ipa_ramdisk_checksum_url:
29+
30+
# Algorithm of checksum of Ironic Python Agent (IPA) ramdisk image.
31+
#inspector_ipa_ramdisk_checksum_algorithm:
32+
33+
###############################################################################
34+
# Ironic inspector processing configuration.
35+
36+
# List of of default inspector processing plugins.
37+
#inspector_processing_hooks_default:
38+
39+
# List of of additional inspector processing plugins.
40+
inspector_processing_hooks_extra:
41+
- system_name_llc
42+
- system_name_physnet
43+
44+
# List of of additional inspector processing plugins.
45+
#inspector_processing_hooks:
46+
47+
# Which MAC addresses to add as ports during introspection. One of 'all',
48+
# 'active' or 'pxe'.
49+
inspector_add_ports: all
50+
51+
# Which ports to keep after introspection. One of 'all', 'present', or 'added'.
52+
inspector_keep_ports: added
53+
54+
# Whether to enable discovery of nodes not managed by Ironic.
55+
#inspector_enable_discovery:
56+
57+
# The Ironic driver with which to register newly discovered nodes.
58+
inspector_discovery_enroll_node_driver: ipmi
59+
60+
###############################################################################
61+
# Ironic inspector configuration.
62+
63+
# Ironic inspector option to enable IPMI rules. Set to 'True' by default.
64+
#inspector_rules_ipmi_enabled:
65+
66+
# Ironic inspector IPMI username to set.
67+
#inspector_ipmi_username:
68+
69+
# Ironic inspector IPMI password to set.
70+
#inspector_ipmi_password:
71+
72+
# Ironic inspector default network interface name on which to check for an LLDP
73+
# switch port description to use as the node's name.
74+
#inspector_lldp_switch_port_interface_default:
75+
76+
# Ironic inspector map from hostname to network interface name on which to
77+
# check for an LLDP switch port description to use as the node's name.
78+
#inspector_lldp_switch_port_interface_map:
79+
80+
# Ironic inspector uses IPMI by default enroll the baremetal nodes, however it
81+
# is possible to use Redfish instead. To do that enable Redfish and make sure
82+
# all of the necessary variables below have been properly set.
83+
# Enable inspector Redfish rules. Set to 'False' by default.
84+
#inspector_rules_redfish_enabled:
85+
86+
# Ironic inspector Redfish username to set.
87+
#inspector_redfish_username:
88+
89+
# Ironic inspector Redfish password to set.
90+
#inspector_redfish_password:
91+
92+
# Redfish CA setting. Set to 'True' by default
93+
#inspector_rule_var_redfish_verify_ca:
94+
95+
###############################################################################
96+
# Ironic inspector introspection rules configuration.
97+
98+
# Ironic inspector rule to set IPMI credentials.
99+
#inspector_rule_ipmi_credentials:
100+
101+
# Ironic inspector rule to set deployment kernel.
102+
#inspector_rule_deploy_kernel:
103+
104+
# Ironic inspector rule to set deployment ramdisk.
105+
#inspector_rule_deploy_ramdisk:
106+
107+
# Ironic inspector rule to initialise root device hints.
108+
#inspector_rule_root_hint_init:
109+
110+
# Ironic inspector rule to set serial root device hint.
111+
#inspector_rule_root_hint_serial:
112+
113+
# Ironic inspector rule to set the interface on which the node PXE booted.
114+
#inspector_rule_set_pxe_interface_mac:
115+
116+
# Ironic inspector rule to set the node's name from an interface's LLDP switch
117+
# port description.
118+
#inspector_rule_lldp_switch_port_desc_to_name:
119+
120+
# Ironic inspector rule to save introspection data to the node.
121+
#inspector_rule_save_data:
122+
123+
# List of default ironic inspector rules.
124+
#inspector_rules_default:
125+
126+
# List of additional ironic inspector rules.
127+
#inspector_rules_extra:
128+
129+
# List of all ironic inspector rules.
130+
#inspector_rules:
131+
132+
###############################################################################
133+
# Dell switch LLDP workaround configuration.
134+
135+
# Some Dell switch OSs (including Dell Network OS 9.10(0.1)) do not support
136+
# sending interface port description TLVs correctly. Instead of sending the
137+
# interface description, they send the interface name (e.g. TenGigabitEthernet
138+
# 1/1/1). This breaks the discovery process which relies on Ironic node
139+
# introspection data containing the node's name in the interface port
140+
# description. We work around this here by creating an introspection rule for
141+
# each ironic node that matches against the switch system and the relevant
142+
# interface name, then sets the node's name appropriately.
143+
144+
# Ansible group containing switch hosts to which the workaround should be
145+
# applied.
146+
#inspector_dell_switch_lldp_workaround_group:
147+
148+
###############################################################################
149+
# Inspection store configuration.
150+
# The inspection store provides a Swift-like service for storing inspection
151+
# data which may be useful in environments without Swift.
152+
153+
# Whether the inspection data store is enabled.
154+
#inspector_store_enabled:
155+
156+
# Port on which the inspection data store should listen.
157+
#inspector_store_port:
158+
159+
###############################################################################
160+
# Dummy variable to allow Ansible to accept this file.
161+
workaround_ansible_issue_8743: yes
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
ironic_driver: ipmi
3+
4+
ironic_driver_info:
5+
ipmi_address: "{{ ironic_ipmi_address }}"
6+
ipmi_username: "{{ ironic_ipmi_username }}"
7+
ipmi_password: "{{ ironic_ipmi_password }}"
8+
ipmi_verify_ca: "{{ ironic_ipmi_verify_ca }}"
9+
10+
ironic_properties:
11+
capabilities: "{{ ironic_capabilities }}"
12+
13+
ironic_ipmi_verify_ca: false
14+
ironic_ipmi_address: "{{ ipmi_address }}"
15+
ironic_ipmi_username: "{{ secrets_ipmi_baremetal_username }}"
16+
ironic_ipmi_password: "{{ secrets_ipmi_baremetal_password }}"
17+
ironic_capabilities: "boot_option:local,boot_mode:uefi"

etc/kayobe/environments/stack-ironic-ipmi/inventory/hosts

Whitespace-only changes.
Lines changed: 151 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,151 @@
1+
---
2+
###############################################################################
3+
# Ironic configuration.
4+
5+
# Specify the list of hardware types to load during service initialization.
6+
kolla_ironic_enabled_hardware_types:
7+
- ipmi
8+
9+
# Specify the list of bios interfaces to load during service initialization.
10+
kolla_ironic_enabled_bios_interfaces:
11+
- no-bios
12+
13+
# Default bios interface to be used for nodes that do not have bios_interface
14+
# field set.
15+
kolla_ironic_default_bios_interface: no-bios
16+
17+
# Specify the list of boot interfaces to load during service initialization.
18+
kolla_ironic_enabled_boot_interfaces:
19+
- ipxe
20+
- pxe
21+
22+
# Default boot interface to be used for nodes that do not have boot_interface
23+
# field set.
24+
kolla_ironic_default_boot_interface: ipxe
25+
26+
# Specify the list of console interfaces to load during service initialization.
27+
kolla_ironic_enabled_console_interfaces:
28+
- ipmitool-socat
29+
- no-console
30+
31+
# Default console interface to be used for nodes that do not have
32+
# console_interface field set.
33+
kolla_ironic_default_console_interface: ipmitool-socat
34+
35+
# Specify the list of deploy interfaces to load during service initialization.
36+
kolla_ironic_enabled_deploy_interfaces:
37+
- direct
38+
39+
# Default deploy interface to be used for nodes that do not have
40+
# deploy_interface field set.
41+
kolla_ironic_default_deploy_interface: direct
42+
43+
# Specify the list of inspect interfaces to load during service initialization.
44+
kolla_ironic_enabled_inspect_interfaces:
45+
- inspector
46+
- no-inspect
47+
48+
# Default inspect interface to be used for nodes that do not have
49+
# inspect_interface field set.
50+
kolla_ironic_default_inspect_interface: inspector
51+
52+
# Specify the list of management interfaces to load during service
53+
# initialization.
54+
kolla_ironic_enabled_management_interfaces:
55+
- ipmitool
56+
57+
# Default management interface to be used for nodes that do not have
58+
# management_interface field set.
59+
kolla_ironic_default_management_interface: ipmitool
60+
61+
# Specify the list of network interfaces to load during service initialization.
62+
kolla_ironic_enabled_network_interfaces:
63+
- noop
64+
- flat
65+
- neutron
66+
67+
# Default network interface to be used for nodes that do not have
68+
# network_interface field set.
69+
kolla_ironic_default_network_interface: neutron
70+
71+
# Specify the list of power interfaces to load during service initialization.
72+
kolla_ironic_enabled_power_interfaces:
73+
- ipmitool
74+
75+
# Default power interface to be used for nodes that do not have power_interface
76+
# field set.
77+
kolla_ironic_default_power_interface: ipmitool
78+
79+
# Specify the list of raid interfaces to load during service initialization.
80+
kolla_ironic_enabled_raid_interfaces:
81+
- agent
82+
- no-raid
83+
84+
# Default raid interface to be used for nodes that do not have
85+
# raid_interface field set.
86+
kolla_ironic_default_raid_interface: no-raid
87+
88+
# Specify the list of rescue interfaces to load during service initialization.
89+
kolla_ironic_enabled_rescue_interfaces:
90+
- agent
91+
- no-rescue
92+
93+
# Default rescue interface to be used for nodes that do not have
94+
# rescue_interface field set.
95+
kolla_ironic_default_rescue_interface: no-rescue
96+
97+
# Specify the list of storage interfaces to load during
98+
# service initialization.
99+
#kolla_ironic_enabled_storage_interfaces:
100+
101+
# Default storage interface to be used for nodes that do not
102+
# have storage_interface field set.
103+
#kolla_ironic_default_storage_interface:
104+
105+
# Specify the list of vendor interfaces to load during service initialization.
106+
kolla_ironic_enabled_vendor_interfaces:
107+
- no-vendor
108+
109+
# Default vendor interface to be used for nodes that do not have
110+
# vendor_interface field set.
111+
kolla_ironic_default_vendor_interface: no-vendor
112+
113+
# Name of the Neutron network to use for cleaning.
114+
kolla_ironic_cleaning_network: "{{ kolla_ironic_provisioning_network if cleaning_net_name == provision_wl_net_name else 'cleaning-net' }}"
115+
116+
# Name of the Neutron network to use for provisioning.
117+
kolla_ironic_provisioning_network: 'provision-net'
118+
119+
# List of default kernel parameters to append for baremetal PXE boot.
120+
kolla_ironic_pxe_append_params_default:
121+
- nofb
122+
- nomodeset
123+
- vga=normal
124+
- console=tty0
125+
- console=ttyS0,115200n8
126+
127+
# List of additional kernel parameters to append for baremetal PXE boot.
128+
kolla_ironic_pxe_append_params_extra: []
129+
130+
# List of kernel parameters to append for baremetal PXE boot.
131+
kolla_ironic_pxe_append_params: >
132+
{{ kolla_ironic_pxe_append_params_default +
133+
kolla_ironic_pxe_append_params_extra }}
134+
135+
###############################################################################
136+
# Ironic Node Configuration
137+
138+
# Whether or not to enable the serial consoles on post configure
139+
ironic_serial_console_autoenable: false
140+
141+
# This defines the start of the range of TCP ports to used for the IPMI socat
142+
# serial consoles
143+
ironic_serial_console_tcp_pool_start: 30000
144+
145+
# This defines the end of the range of TCP ports to used for the IPMI socat
146+
# serial consoles
147+
ironic_serial_console_tcp_pool_end: 31000
148+
149+
###############################################################################
150+
# Dummy variable to allow Ansible to accept this file.
151+
workaround_ansible_issue_8743: yes
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
dependencies:
3+
- stack-ironic

0 commit comments

Comments
 (0)