aboutsummaryrefslogtreecommitdiffstats
path: root/puppet/extraconfig/pre_deploy/controller
diff options
context:
space:
mode:
authorSteven Hardy <shardy@redhat.com>2015-09-10 10:17:16 -0400
committerSteven Hardy <shardy@redhat.com>2015-09-17 15:50:39 +0100
commit81785633bd33b3e5c8cf47c39b8ea2525b7e630a (patch)
treebc28ce7ec515519c42c5229924bb3274118bbdd6 /puppet/extraconfig/pre_deploy/controller
parent196e6f3ff6cb9d261d8c8f872d43deb129b1a2e8 (diff)
Port Cisco Nexus/UCSM ExtraConfig to AllNodes
Switch the implemention from a pre_deploy ExtraConfig to an AllNodesExtraConfig, so we can collect the mac->hostname mapping for all nodes, then calculate a NexusConfig based on that and a provided mapping of switch ports to mac address. The same conversion is also done to the NetworkUCSMHostList: The port mappings are provided via parameter_defaults like: parameter_defaults: NetworkNexusConfig: { "bxb-tor-1": { "username": "admin", "ssh_port": 22, "password": "lab", "ip_address": "10.86.7.204", "nve_src_intf": 0, "physnet": "datacentre", "servers": { "fa:16:3e:fa:be:ef": "1/11", "fa:16:3e:fa:5e:cf": "1/23", "fa:16:3e:fa:12:34": "2/34" } } } NetworkUCSMHostList: 'fa:16:3e:fa:be:ef:profile1' This results in an entry like this appended to /etc/puppet/hieradata/neutron_cisco_data.yaml: neutron::plugins::ml2::cisco::nexus::nexus_config:\ {"bxb-tor-1": {"username": "admin", "nve_src_intf": 0, "ssh_port": 22, "servers": {"overcloud-compute02": "2/34", "overcloud-compute01": "1/23", "overcloud-control01": "1/11"}, "password": "lab", "ip_address": "10.86.7.204", "physnet": "datacentre"}} neutron::plugins::ml2::cisco::ucsm::ucsm_host_list: overcloud-control01:profile1 Co-Authored-By: Rob Pothier <rpothier@cisco.com> Co-Authored-By: Tim Swanson <tiswanso@cisco.com> Change-Id: I372c3ffb6bd85b7239fcb9f3fc4fa51cd4a39332
Diffstat (limited to 'puppet/extraconfig/pre_deploy/controller')
-rw-r--r--puppet/extraconfig/pre_deploy/controller/network-cisco.yaml141
1 files changed, 0 insertions, 141 deletions
diff --git a/puppet/extraconfig/pre_deploy/controller/network-cisco.yaml b/puppet/extraconfig/pre_deploy/controller/network-cisco.yaml
deleted file mode 100644
index ed3bf291..00000000
--- a/puppet/extraconfig/pre_deploy/controller/network-cisco.yaml
+++ /dev/null
@@ -1,141 +0,0 @@
-heat_template_version: 2015-04-30
-
-description: Configure hieradata for Network Cisco configuration
-
-parameters:
- server:
- description: ID of the controller node to apply this config to
- type: string
-
- NetworkUCSMIp:
- type: string
- description: Cisco UCSM IP
- default: 127.0.0.1
- NetworkUCSMUsername:
- type: string
- description: Cisco UCSM username
- default: admin
- NetworkUCSMPassword:
- type: string
- description: Cisco UCSM password
- default: password
- NetworkUCSMHostList:
- type: string
- description: Cisco UCSM hostname
- default: 127.0.0.1
- NetworkUCSMSupportedPciDevs:
- type: string
- description: Cisco UCSM SR-IOV and VM-FEX vendors supported
- default: ''
- NetworkNexusConfig:
- type: json
- description: Nexus switch configuration
- default: {}
- NetworkNexusManagedPhysicalNetwork:
- type: string
- description: The name of the physical_network
- default: ''
- NetworkNexusVlanNamePrefix:
- type: string
- description: A short prefix to prepend to the VLAN name
- default: 'q-'
- NetworkNexusSviRoundRobin:
- type: boolean
- description: A flag to enable round robin scheduling
- default: false
- NetworkNexusProviderVlanNamePrefix:
- type: string
- description: A short prefix to prepend to the VLAN name
- default: 'p-'
- NetworkNexusPersistentSwitchConfig:
- type: string
- description: To make Nexus device persistent
- default: false
- NetworkNexusSwitchHeartbeatTime:
- type: number
- description: Time interval to check the state of the Nexus device
- default: 0
- NetworkNexusSwitchReplayCount:
- type: number
- description: Number of times to attempt config replay
- default: 3
- NetworkNexusProviderVlanAutoCreate:
- type: boolean
- description: A flag whether to manage the creation and removal of VLANs
- default: true
- NetworkNexusProviderVlanAutoTrunk:
- type: boolean
- description: A flag whether to manage the trunk ports on the Nexus
- default: true
- NetworkNexusVxlanGlobalConfig:
- type: boolean
- description: A flag whether to manage the VXLAN global settings
- default: true
- NetworkNexusHostKeyChecks:
- type: boolean
- description: enable strict host key checks when connecting to Nexus switches
- default: false
- NetworkNexusVxlanVniRanges:
- type: string
- description: VXLAN Network IDs that are available for tenant network
- default: ''
- NetworkNexusVxlanMcastRanges:
- type: string
- description: Multicast groups for the VXLAN interface.
- default: ''
-
-resources:
- NetworkCiscoConfig:
- type: OS::Heat::StructuredConfig
- properties:
- group: os-apply-config
- config:
- hiera:
- datafiles:
- neutron_cisco_data:
- mapped_data:
- neutron::plugins::ml2::cisco::ucsm::ucsm_ip: {get_input: UCSM_ip}
- neutron::plugins::ml2::cisco::ucsm::ucsm_username: {get_input: UCSM_username}
- neutron::plugins::ml2::cisco::ucsm::ucsm_password: {get_input: UCSM_password}
- neutron::plugins::ml2::cisco::ucsm::ucsm_host_list: {get_input: UCSM_host_list}
- neutron::plugins::ml2::cisco::ucsm::supported_pci_devs: {get_input: UCSMSupportedPciDevs}
- neutron::plugins::ml2::cisco::nexus::nexus_config: {get_input: NexusConfig}
- neutron::plugins::ml2::cisco::nexus::managed_physical_network: {get_input: NexusManagedPhysicalNetwork}
- neutron::plugins::ml2::cisco::nexus::vlan_name_prefix: {get_input: NexusVlanNamePrefix}
- neutron::plugins::ml2::cisco::nexus::svi_round_robin: {get_input: NexusSviRoundRobin}
- neutron::plugins::ml2::cisco::nexus::provider_vlan_name_prefix: {get_input: NexusProviderVlanNamePrefix}
- neutron::plugins::ml2::cisco::nexus::persistent_switch_config: {get_input: NexusPersistentSwitchConfig}
- neutron::plugins::ml2::cisco::nexus::switch_heartbeat_time: {get_input: NexusSwitchHeartbeatTime}
- neutron::plugins::ml2::cisco::nexus::switch_replay_count: {get_input: NexusSwitchReplayCount}
- neutron::plugins::ml2::cisco::nexus::provider_vlan_auto_create: {get_input: NexusProviderVlanAutoCreate}
- neutron::plugins::ml2::cisco::nexus::provider_vlan_auto_trunk: {get_input: NexusProviderVlanAutoTrunk}
- neutron::plugins::ml2::cisco::nexus::vxlan_global_config: {get_input: NexusVxlanGlobalConfig}
- neutron::plugins::ml2::cisco::nexus::host_key_checks: {get_input: NexusHostKeyChecks}
- neutron::plugins::ml2::cisco::type_nexus_vxlan::vni_ranges: {get_input: NexusVxlanVniRanges}
- neutron::plugins::ml2::cisco::type_nexus_vxlan::mcast_ranges: {get_input: NexusVxlanMcastRanges}
-
- NetworkCiscoDeployment:
- type: OS::Heat::StructuredDeployment
- properties:
- config: {get_resource: NetworkCiscoConfig}
- server: {get_param: server}
- input_values:
- UCSM_ip: {get_param: NetworkUCSMIp}
- UCSM_username: {get_param: NetworkUCSMUsername}
- UCSM_password: {get_param: NetworkUCSMPassword}
- UCSM_host_list: {get_param: NetworkUCSMHostList}
- UCSMSupportedPciDevs: {get_param: NetworkUCSMSupportedPciDevs}
- NexusConfig: {get_param: NetworkNexusConfig}
- NexusManagedPhysicalNetwork: {get_param: NetworkNexusManagedPhysicalNetwork}
- NexusVlanNamePrefix: {get_param: NetworkNexusVlanNamePrefix}
- NexusSviRoundRobin: {get_param: NetworkNexusSviRoundRobin}
- NexusProviderVlanNamePrefix: {get_param: NetworkNexusProviderVlanNamePrefix}
- NexusPersistentSwitchConfig: {get_param: NetworkNexusPersistentSwitchConfig}
- NexusSwitchHeartbeatTime: {get_param: NetworkNexusSwitchHeartbeatTime}
- NexusSwitchReplayCount: {get_param: NetworkNexusSwitchReplayCount}
- NexusProviderVlanAutoCreate: {get_param: NetworkNexusProviderVlanAutoCreate}
- NexusProviderVlanAutoTrunk: {get_param: NetworkNexusProviderVlanAutoTrunk}
- NexusVxlanGlobalConfig: {get_param: NetworkNexusVxlanGlobalConfig}
- NexusHostKeyChecks: {get_param: NetworkNexusHostKeyChecks}
- NexusVxlanVniRanges: {get_param: NetworkNexusVxlanVniRanges}
- NexusVxlanMcastRanges: {get_param: NetworkNexusVxlanMcastRanges}