From 34edcd2be3075b8c935c50e4743ce7c230bfd45f Mon Sep 17 00:00:00 2001 From: Dan Prince Date: Tue, 18 Apr 2017 15:35:38 -0400 Subject: [PATCH] Add advanced features to ironic-inspector templates Change-Id: Ib70f1a815d37961263b48f0791f487e108addf97 Co-Authored-By: Dmitry Tantsur --- environments/undercloud.yaml | 1 + puppet/services/ironic-inspector.yaml | 38 +++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/environments/undercloud.yaml b/environments/undercloud.yaml index 4bc16f8c29..6ca6ade59a 100644 --- a/environments/undercloud.yaml +++ b/environments/undercloud.yaml @@ -18,6 +18,7 @@ parameter_defaults: HeatConvergenceEngine: false HeatMaxResourcesPerStack: -1 HeatMaxJsonBodySize: 2097152 + IronicInspectorCollectors: default,extra-hardware,numa-topology,logs IronicInspectorInterface: br-ctlplane IronicInspectorIpRange: '192.168.24.100,192.168.24.200' ZaqarMessageStore: 'swift' diff --git a/puppet/services/ironic-inspector.yaml b/puppet/services/ironic-inspector.yaml index 3ec75ac7b1..06c425db5b 100644 --- a/puppet/services/ironic-inspector.yaml +++ b/puppet/services/ironic-inspector.yaml @@ -41,6 +41,30 @@ parameters: default: false description: Set to True to enable debugging on all services. type: boolean + IronicInspectorDiscoveryDefaultDriver: + default: 'ipmi' + description: | + The default driver to use for newly discovered nodes + (requires IronicInspectorEnableNodeDiscovery set to True). This + driver is automatically added to enabled_drivers. + type: string + IronicInspectorEnableNodeDiscovery: + default: false + description: | + Makes ironic-inspector enroll any unknown node that PXE-boots + introspection ramdisk in Ironic. The default driver to use for new nodes + is specified by the IronicInspectorDiscoveryDefaultDriver parameter. + Introspection rules can also be used to specify it. + type: boolean + IronicInspectorCollectors: + default: default,logs + description: Comma-separated list of IPA inspection collectors + type: string + IronicInspectorExtraProcessingHooks: + default: extra_hardware,lldp_basic,local_link_connection + description: | + Comma-separated list of processing hooks to append to the default list. + type: string IronicInspectorInterface: default: br-ex description: | @@ -52,6 +76,10 @@ parameters: default: true description: Whether to use iPXE for inspection. type: boolean + IronicInspectorKernelArgs: + default: 'ipa-inspection-dhcp-all-interfaces=1 ipa-collect-lldp=1 ipa-debug=1' + description: Kernel args for the Ironic inspector. + type: string IronicInspectorIpRange: description: | Temporary IP range that will be given to nodes during the inspection @@ -75,6 +103,7 @@ parameters: conditions: enable_ipxe: {equals : [{get_param: IronicInspectorIPXEEnabled}, true]} use_swift: {equals : [{get_param: IronicInspectorUseSwift}, true]} + enable_node_discovery: {equals : [{get_param: IronicInspectorEnableNodeDiscovery}, true]} outputs: role_data: @@ -109,6 +138,9 @@ outputs: ironic::inspector::ironic_user_domain_name: 'Default' ironic::inspector::ironic_project_domain_name: 'Default' ironic::inspector::http_port: {get_param: IronicIPXEPort} + ironic::inspector::additional_processing_hooks: {get_param: IronicInspectorExtraProcessingHooks} + ironic::inspector::ramdisk_collectors: {get_param: IronicInspectorCollectors} + ironic::inspector::ramdisk_kernel_args: {get_param: IronicInspectorKernelArgs} ironic::inspector::db::database_connection: list_join: - '' @@ -135,6 +167,12 @@ outputs: ironic::inspector::swift_user_domain_name: 'Default' ironic::inspector::swift_project_domain_name: 'Default' - {} + - + if: + - enable_node_discovery + - ironic::inspector::node_not_found_hook: 'enroll' + ironic::inspector::discovery_default_driver: {get_param: IronicInspectorDiscoveryDefaultDriver} + - {} step_config: | include ::tripleo::profile::base::ironic_inspector service_config_settings: