967b66e11b998d22d2cc10cb6ee0f6511b3f7a6b
[apex-tripleo-heat-templates.git] / network / ports / management.yaml
1 heat_template_version: 2015-10-15
2
3 description: >
4   Creates a port on the management network. The IP address will be chosen
5   automatically if FixedIPs is empty.
6
7 parameters:
8   ManagementNetName:
9     description: Name of the management neutron network
10     default: management
11     type: string
12   PortName:
13     description: Name of the port
14     default: ''
15     type: string
16   ControlPlaneIP: # Here for compatibility with noop.yaml
17     description: IP address on the control plane
18     type: string
19   IPPool: # Here for compatibility with from_pool.yaml
20     default: {}
21     type: json
22   NodeIndex: # Here for compatibility with from_pool.yaml
23     default: 0
24     type: number
25
26 resources:
27
28   ManagementPort:
29     type: OS::Neutron::Port
30     properties:
31       network: {get_param: ManagementNetName}
32       name: {get_param: PortName}
33       replacement_policy: AUTO
34
35 outputs:
36   ip_address:
37     description: management network IP
38     value: {get_attr: [ManagementPort, fixed_ips, 0, ip_address]}
39   ip_address_uri:
40     description: management network IP (for compatibility with management_v6.yaml)
41     value: {get_attr: [ManagementPort, fixed_ips, 0, ip_address]}
42   ip_subnet:
43     description: IP/Subnet CIDR for the management network IP
44     value:
45           list_join:
46             - ''
47             - - {get_attr: [ManagementPort, fixed_ips, 0, ip_address]}
48               - '/'
49               - {str_split: ['/', {get_attr: [ManagementPort, subnets, 0, cidr]}, 1]}