Abstract undercloud network creation
Doing this make it possible to override the network configuration and deploy more/different networks.
This commit is contained in:
parent
ca2f47d343
commit
0ee82cd296
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -46,7 +41,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
internal_port:
|
||||
@ -106,7 +101,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
outputs:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -46,7 +41,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
|
||||
internal_port:
|
||||
type: OS::Neutron::Port
|
||||
@ -101,7 +96,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
|
||||
outputs:
|
||||
ports:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -26,7 +21,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
outputs:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -26,7 +21,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
|
||||
outputs:
|
||||
ports:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
private_net:
|
||||
type: string
|
||||
@ -62,7 +57,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
public_port:
|
||||
@ -74,7 +69,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
extra_node_fip:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
private_net:
|
||||
type: string
|
||||
@ -59,7 +54,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
public_port:
|
||||
@ -71,7 +66,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
outputs:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -46,7 +41,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
internal_port:
|
||||
@ -106,7 +101,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
public_bond_port:
|
||||
@ -118,7 +113,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
outputs:
|
||||
|
@ -5,13 +5,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of external network
|
||||
default: public
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -46,7 +41,7 @@ resources:
|
||||
- ''
|
||||
- - {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
|
||||
internal_port:
|
||||
type: OS::Neutron::Port
|
||||
@ -101,7 +96,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
|
||||
public_bond_port:
|
||||
type: OS::Neutron::Port
|
||||
@ -112,7 +107,7 @@ resources:
|
||||
- - public_
|
||||
- {get_param: baremetal_prefix}
|
||||
- {get_param: suffix}
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
|
||||
outputs:
|
||||
ports:
|
||||
|
@ -49,36 +49,6 @@ parameters:
|
||||
default: external
|
||||
description: An external network from which floating ips can be provisioned
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
default: provision
|
||||
description: Name of a network that will be used for provisioning traffic
|
||||
|
||||
provision_net_cidr:
|
||||
type: string
|
||||
description: CIDR for provision network subnet
|
||||
default: 192.0.2.0/24
|
||||
|
||||
provision_net_shared:
|
||||
type: boolean
|
||||
description: Whether this network should be shared across all tenants
|
||||
default: false
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of the overcloud external network
|
||||
default: public
|
||||
|
||||
public_net_cidr:
|
||||
type: string
|
||||
description: CIDR for external network subnet
|
||||
default: 10.0.0.0/24
|
||||
|
||||
public_net_shared:
|
||||
type: boolean
|
||||
description: Whether this network should be shared across all tenants
|
||||
default: false
|
||||
|
||||
bmc_prefix:
|
||||
type: string
|
||||
default: bmc
|
||||
@ -173,35 +143,8 @@ parameters:
|
||||
|
||||
|
||||
resources:
|
||||
provision_network:
|
||||
type: OS::Neutron::Net
|
||||
properties:
|
||||
name: {get_param: provision_net}
|
||||
shared: {get_param: provision_net_shared}
|
||||
|
||||
provision_subnet:
|
||||
type: OS::Neutron::Subnet
|
||||
properties:
|
||||
network: {get_resource: provision_network}
|
||||
name: {get_param: provision_net}
|
||||
cidr: {get_param: provision_net_cidr}
|
||||
gateway_ip: null
|
||||
enable_dhcp: false
|
||||
|
||||
public_network:
|
||||
type: OS::Neutron::Net
|
||||
properties:
|
||||
name: {get_param: public_net}
|
||||
shared: {get_param: public_net_shared}
|
||||
|
||||
public_subnet:
|
||||
type: OS::Neutron::Subnet
|
||||
properties:
|
||||
network: {get_resource: public_network}
|
||||
name: {get_param: public_net}
|
||||
cidr: {get_param: public_net_cidr}
|
||||
gateway_ip: null
|
||||
enable_dhcp: false
|
||||
undercloud_networks:
|
||||
type: OS::OVB::UndercloudNetworks
|
||||
|
||||
private_network:
|
||||
type: OS::OVB::PrivateNetwork
|
||||
@ -211,7 +154,7 @@ resources:
|
||||
|
||||
undercloud_env:
|
||||
type: OS::OVB::UndercloudEnvironment
|
||||
depends_on: [provision_subnet, public_subnet]
|
||||
depends_on: [undercloud_networks, private_network]
|
||||
properties:
|
||||
undercloud_flavor: {get_param: undercloud_flavor}
|
||||
undercloud_image: {get_param: undercloud_image}
|
||||
@ -220,21 +163,19 @@ resources:
|
||||
undercloud_user_data_format: {get_param: undercloud_user_data_format}
|
||||
undercloud_user_data: {get_param: undercloud_user_data}
|
||||
private_net: {get_attr: [private_network, private_net]}
|
||||
provision_net: {get_resource: provision_network}
|
||||
public_net: {get_resource: public_network}
|
||||
networks: {get_attr: [undercloud_networks, networks]}
|
||||
external_net: {get_param: external_net}
|
||||
|
||||
baremetal_env:
|
||||
type: OS::OVB::BaremetalEnvironment
|
||||
depends_on: [provision_subnet, public_subnet]
|
||||
depends_on: undercloud_networks
|
||||
properties:
|
||||
baremetal_flavor: {get_param: baremetal_flavor}
|
||||
baremetal_image: {get_param: baremetal_image}
|
||||
key_name: {get_param: key_name}
|
||||
node_count: {get_param: node_count}
|
||||
public_net: {get_resource: public_network}
|
||||
private_net: {get_attr: [private_network, private_net]}
|
||||
provision_net: {get_resource: provision_network}
|
||||
networks: {get_attr: [undercloud_networks, networks]}
|
||||
bmc_flavor: {get_param: bmc_flavor}
|
||||
bmc_prefix: {get_param: bmc_prefix}
|
||||
bmc_image: {get_param: bmc_image}
|
||||
|
@ -8,3 +8,4 @@ resource_registry:
|
||||
OS::OVB::BaremetalPorts: baremetal-ports-default.yaml
|
||||
OS::OVB::BMCPort: bmc-port.yaml
|
||||
OS::OVB::UndercloudPorts: undercloud-ports.yaml
|
||||
OS::OVB::UndercloudNetworks: undercloud-networks.yaml
|
||||
|
69
templates/undercloud-networks.yaml
Normal file
69
templates/undercloud-networks.yaml
Normal file
@ -0,0 +1,69 @@
|
||||
heat_template_version: 2015-04-30
|
||||
|
||||
parameters:
|
||||
provision_net:
|
||||
type: string
|
||||
default: provision
|
||||
description: Name of a network that will be used for provisioning traffic
|
||||
|
||||
provision_net_cidr:
|
||||
type: string
|
||||
description: CIDR for provision network subnet
|
||||
default: 192.0.2.0/24
|
||||
|
||||
provision_net_shared:
|
||||
type: boolean
|
||||
description: Whether this network should be shared across all tenants
|
||||
default: false
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: Name of the overcloud external network
|
||||
default: public
|
||||
|
||||
public_net_cidr:
|
||||
type: string
|
||||
description: CIDR for external network subnet
|
||||
default: 10.0.0.0/24
|
||||
|
||||
public_net_shared:
|
||||
type: boolean
|
||||
description: Whether this network should be shared across all tenants
|
||||
default: false
|
||||
|
||||
resources:
|
||||
provision_network:
|
||||
type: OS::Neutron::Net
|
||||
properties:
|
||||
name: {get_param: provision_net}
|
||||
shared: {get_param: provision_net_shared}
|
||||
|
||||
provision_subnet:
|
||||
type: OS::Neutron::Subnet
|
||||
properties:
|
||||
network: {get_resource: provision_network}
|
||||
name: {get_param: provision_net}
|
||||
cidr: {get_param: provision_net_cidr}
|
||||
gateway_ip: null
|
||||
enable_dhcp: false
|
||||
|
||||
public_network:
|
||||
type: OS::Neutron::Net
|
||||
properties:
|
||||
name: {get_param: public_net}
|
||||
shared: {get_param: public_net_shared}
|
||||
|
||||
public_subnet:
|
||||
type: OS::Neutron::Subnet
|
||||
properties:
|
||||
network: {get_resource: public_network}
|
||||
name: {get_param: public_net}
|
||||
cidr: {get_param: public_net_cidr}
|
||||
gateway_ip: null
|
||||
enable_dhcp: false
|
||||
|
||||
outputs:
|
||||
networks:
|
||||
value:
|
||||
provision: {get_resource: provision_network}
|
||||
public: {get_resource: public_network}
|
@ -8,11 +8,8 @@ parameters:
|
||||
private_net:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
networks:
|
||||
type: json
|
||||
|
||||
resources:
|
||||
undercloud_sg:
|
||||
@ -53,7 +50,7 @@ resources:
|
||||
- '_'
|
||||
- - {get_param: undercloud_name}
|
||||
- 'provision'
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
port_security_enabled: False
|
||||
|
||||
public_undercloud_port:
|
||||
@ -64,7 +61,7 @@ resources:
|
||||
- '_'
|
||||
- - {get_param: undercloud_name}
|
||||
- 'public'
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
port_security_enabled: False
|
||||
|
||||
outputs:
|
||||
|
@ -8,11 +8,8 @@ parameters:
|
||||
private_net:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
networks:
|
||||
type: json
|
||||
|
||||
resources:
|
||||
undercloud_sg:
|
||||
@ -53,7 +50,7 @@ resources:
|
||||
- '_'
|
||||
- - {get_param: undercloud_name}
|
||||
- 'provision'
|
||||
network: {get_param: provision_net}
|
||||
network: {get_param: [networks, provision]}
|
||||
|
||||
public_undercloud_port:
|
||||
type: OS::Neutron::Port
|
||||
@ -63,7 +60,7 @@ resources:
|
||||
- '_'
|
||||
- - {get_param: undercloud_name}
|
||||
- 'public'
|
||||
network: {get_param: public_net}
|
||||
network: {get_param: [networks, public]}
|
||||
|
||||
outputs:
|
||||
ports:
|
||||
|
@ -19,10 +19,8 @@ parameters:
|
||||
description: The size of the volume for the undercloud instance
|
||||
private_net:
|
||||
type: string
|
||||
provision_net:
|
||||
type: string
|
||||
public_net:
|
||||
type: string
|
||||
networks:
|
||||
type: json
|
||||
external_net:
|
||||
type: string
|
||||
|
||||
@ -32,8 +30,7 @@ resources:
|
||||
properties:
|
||||
undercloud_name: {get_param: undercloud_name}
|
||||
private_net: {get_param: private_net}
|
||||
provision_net: {get_param: provision_net}
|
||||
public_net: {get_param: public_net}
|
||||
networks: {get_param: networks}
|
||||
|
||||
undercloud_volume:
|
||||
type: OS::Cinder::Volume
|
||||
|
@ -15,10 +15,8 @@ parameters:
|
||||
type: string
|
||||
private_net:
|
||||
type: string
|
||||
provision_net:
|
||||
type: string
|
||||
public_net:
|
||||
type: string
|
||||
networks:
|
||||
type: json
|
||||
external_net:
|
||||
type: string
|
||||
|
||||
@ -28,8 +26,7 @@ resources:
|
||||
properties:
|
||||
undercloud_name: {get_param: undercloud_name}
|
||||
private_net: {get_param: private_net}
|
||||
provision_net: {get_param: provision_net}
|
||||
public_net: {get_param: public_net}
|
||||
networks: {get_param: networks}
|
||||
|
||||
undercloud_server:
|
||||
type: OS::Nova::Server
|
||||
|
@ -14,11 +14,8 @@ parameters:
|
||||
baremetal_prefix:
|
||||
type: string
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
networks:
|
||||
type: json
|
||||
|
||||
suffix:
|
||||
type: string
|
||||
@ -30,8 +27,7 @@ resources:
|
||||
properties:
|
||||
suffix: {get_param: suffix}
|
||||
baremetal_prefix: {get_param: baremetal_prefix}
|
||||
provision_net: {get_param: provision_net}
|
||||
public_net: {get_param: public_net}
|
||||
networks: {get_param: networks}
|
||||
|
||||
baremetal_server:
|
||||
type: OS::Nova::Server
|
||||
|
@ -45,22 +45,15 @@ parameters:
|
||||
default: 1
|
||||
description: Number of baremetal nodes to deploy
|
||||
|
||||
public_net:
|
||||
type: string
|
||||
description: |
|
||||
An additional network that will be attached to the baremetal instances,
|
||||
intended to be used for non-provisioning traffic
|
||||
default: public
|
||||
|
||||
private_net:
|
||||
type: string
|
||||
default: private
|
||||
description: Name of a private network which can have floating ips associated with it
|
||||
|
||||
provision_net:
|
||||
type: string
|
||||
default: provision
|
||||
description: Name of a network that will be used for provisioning traffic
|
||||
networks:
|
||||
type: json
|
||||
default: '{"private": "private", "provision": "provision"}'
|
||||
description: A map of networks to their names.
|
||||
|
||||
bmc_prefix:
|
||||
type: string
|
||||
@ -206,7 +199,6 @@ resources:
|
||||
baremetal_flavor: {get_param: baremetal_flavor}
|
||||
baremetal_image: {get_param: baremetal_image}
|
||||
key_name: {get_param: key_name}
|
||||
provision_net: {get_param: provision_net}
|
||||
public_net: {get_param: public_net}
|
||||
networks: {get_param: networks}
|
||||
suffix: _%index%
|
||||
baremetal_prefix: {get_param: baremetal_prefix}
|
||||
|
Loading…
Reference in New Issue
Block a user