Bump template version for all templates to "ocata"
[apex-tripleo-heat-templates.git] / network / config / single-nic-linux-bridge-vlans / controller.yaml
1 heat_template_version: ocata
2 description: >
3   Software Config to drive os-net-config to configure VLANs for the controller role.
4 parameters:
5   ControlPlaneIp:
6     default: ''
7     description: IP address/subnet on the ctlplane network
8     type: string
9   ExternalIpSubnet:
10     default: ''
11     description: IP address/subnet on the external network
12     type: string
13   InternalApiIpSubnet:
14     default: ''
15     description: IP address/subnet on the internal API network
16     type: string
17   StorageIpSubnet:
18     default: ''
19     description: IP address/subnet on the storage network
20     type: string
21   StorageMgmtIpSubnet:
22     default: ''
23     description: IP address/subnet on the storage mgmt network
24     type: string
25   TenantIpSubnet:
26     default: ''
27     description: IP address/subnet on the tenant network
28     type: string
29   ManagementIpSubnet: # Only populated when including environments/network-management.yaml
30     default: ''
31     description: IP address/subnet on the management network
32     type: string
33   ExternalNetworkVlanID:
34     default: 10
35     description: Vlan ID for the external network traffic.
36     type: number
37   InternalApiNetworkVlanID:
38     default: 20
39     description: Vlan ID for the internal_api network traffic.
40     type: number
41   StorageNetworkVlanID:
42     default: 30
43     description: Vlan ID for the storage network traffic.
44     type: number
45   StorageMgmtNetworkVlanID:
46     default: 40
47     description: Vlan ID for the storage mgmt network traffic.
48     type: number
49   TenantNetworkVlanID:
50     default: 50
51     description: Vlan ID for the tenant network traffic.
52     type: number
53   ManagementNetworkVlanID:
54     default: 60
55     description: Vlan ID for the management network traffic.
56     type: number
57   ControlPlaneDefaultRoute: # Override this via parameter_defaults
58     description: The default route of the control plane network.
59     type: string
60   ExternalInterfaceDefaultRoute:
61     default: 10.0.0.1
62     description: default route for the external network
63     type: string
64   ManagementInterfaceDefaultRoute: # Commented out by default in this template
65     default: unset
66     description: The default route of the management network.
67     type: string
68   ControlPlaneSubnetCidr: # Override this via parameter_defaults
69     default: '24'
70     description: The subnet CIDR of the control plane network.
71     type: string
72   DnsServers: # Override this via parameter_defaults
73     default: []
74     description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf.
75     type: comma_delimited_list
76   EC2MetadataIp: # Override this via parameter_defaults
77     description: The IP address of the EC2 metadata server.
78     type: string
79 resources:
80   OsNetConfigImpl:
81     type: OS::Heat::SoftwareConfig
82     properties:
83       group: script
84       config:
85         str_replace:
86           template:
87             get_file: ../../scripts/run-os-net-config.sh
88           params:
89             $network_config:
90               network_config:
91               - type: linux_bridge
92                 name: bridge_name
93                 use_dhcp: false
94                 dns_servers:
95                   get_param: DnsServers
96                 addresses:
97                 - ip_netmask:
98                     list_join:
99                     - /
100                     - - get_param: ControlPlaneIp
101                       - get_param: ControlPlaneSubnetCidr
102                 routes:
103                 - ip_netmask: 169.254.169.254/32
104                   next_hop:
105                     get_param: EC2MetadataIp
106                 - default: true
107                   next_hop:
108                     get_param: ControlPlaneDefaultRoute
109                 members:
110                 - type: interface
111                   name: interface_name
112                   primary: true
113               - type: vlan
114                 vlan_id:
115                   get_param: ExternalNetworkVlanID
116                 device: bridge_name
117                 addresses:
118                 - ip_netmask:
119                     get_param: ExternalIpSubnet
120                 routes:
121                 - default: true
122                   next_hop:
123                     get_param: ExternalInterfaceDefaultRoute
124               - type: vlan
125                 vlan_id:
126                   get_param: InternalApiNetworkVlanID
127                 device: bridge_name
128                 addresses:
129                 - ip_netmask:
130                     get_param: InternalApiIpSubnet
131               - type: vlan
132                 vlan_id:
133                   get_param: StorageNetworkVlanID
134                 device: bridge_name
135                 addresses:
136                 - ip_netmask:
137                     get_param: StorageIpSubnet
138               - type: vlan
139                 vlan_id:
140                   get_param: StorageMgmtNetworkVlanID
141                 device: bridge_name
142                 addresses:
143                 - ip_netmask:
144                     get_param: StorageMgmtIpSubnet
145               - type: vlan
146                 vlan_id:
147                   get_param: TenantNetworkVlanID
148                 device: bridge_name
149                 addresses:
150                 - ip_netmask:
151                     get_param: TenantIpSubnet
152               # Uncomment when including environments/network-management.yaml
153               # If setting default route on the Management interface, comment
154               # out the default route on the External interface. This will
155               # make the External API unreachable from remote subnets.
156               #-
157               #  type: vlan
158               #  vlan_id: {get_param: ManagementNetworkVlanID}
159               #  device: bridge_name
160               #  addresses:
161               #    -
162               #      ip_netmask: {get_param: ManagementIpSubnet}
163               #  routes:
164               #    -
165               #      default: true
166               #      next_hop: {get_param: ManagementInterfaceDefaultRoute}
167 outputs:
168   OS::stack_id:
169     description: The OsNetConfigImpl resource.
170     value:
171       get_resource: OsNetConfigImpl
172