parameters:
  os_user: {{ os_username }}
  os_password: {{ os_password }}
  os_tenant: {{ os_tenant_name }}
  os_auth_url: {{ os_auth_url }}

  bmc_flavor: {{ bmc_flavor }}
  bmc_image: 'bmc-base'
  bmc_prefix: 'bmc-{{ idnum }}'

  baremetal_flavor: {{ baremetal_flavor }}
  baremetal_image: 'ipxe-boot'
  baremetal_prefix: 'baremetal-{{ idnum }}'

  key_name: 'key-{{ idnum }}'
  private_net: 'private-{{ idnum }}'
  node_count: {{ node_count }}
  public_net: 'public-{{ idnum }}'
  provision_net: 'provision-{{ idnum }}'
  provision_net_cidr: {{ provision_net_cidr }}

  # QuintupleO-specific params ignored by virtual-baremetal.yaml
  undercloud_name: 'undercloud-{{ idnum }}'
  undercloud_image: '{{ latest_undercloud_image }}'
  undercloud_flavor: {{ undercloud_flavor }}
  external_net:  '{{ external_net }}'
  undercloud_user_data: |
        #!/bin/sh
        sed -i "s/no-port-forwarding.*sleep 10\" //" /root/.ssh/authorized_keys

parameter_defaults:
## Uncomment and customize the following to use an existing floating ip
#  undercloud_floating_ip_id: 'uuid of floating ip'
#  undercloud_floating_ip: 'address of floating ip'
  # Network Isolation parameters
  overcloud_internal_net: 'overcloud_internal-{{ idnum }}'
  overcloud_storage_net: 'overcloud_storage-{{ idnum }}'
  overcloud_storage_mgmt_net: 'overcloud_storage_mgmt-{{ idnum }}'
  overcloud_tenant_net: 'overcloud_tenant-{{ idnum }}'
  dns_nameservers: '{{ custom_nameserver[0] }}'
{% if boot_from_volume|bool %}
  baremetal_volume_size: '{{ baremetal_boot_from_volume_size }}'
  undercloud_volume_size: '{{ undercloud_boot_from_volume_size }}'
{% endif %}

resource_registry:
## Uncomment the following to use an existing floating ip
#  OS::OVB::UndercloudFloating: templates/undercloud-floating-existing.yaml

## Uncomment the following to use no floating ip
#  OS::OVB::UndercloudFloating: templates/undercloud-floating-none.yaml

## Uncomment the following to create a private network
  OS::OVB::PrivateNetwork: {{ templates_dir }}/private-net-create.yaml

## Uncomment to create all networks required for network-isolation.
## parameter_defaults should be used to override default parameter values
## in baremetal-networks-all.yaml
#  OS::OVB::BaremetalNetworks: {{ templates_dir }}/baremetal-networks-all.yaml
#  OS::OVB::BaremetalPorts: {{ templates_dir }}/baremetal-ports-all.yaml
{% if network_isolation_type in ['multi-nic', 'multiple-nics', 'public-bond'] and not port_security|bool %}
  OS::OVB::BaremetalNetworks: {{ templates_dir }}/baremetal-networks-all.yaml
  OS::OVB::BaremetalPorts: {{ templates_dir }}/{{ baremetal_ports_template[network_isolation_type] }}
{% endif %}
{% if network_isolation_type in ['multi-nic', 'multiple-nics', 'public-bond'] and port_security|bool %}
  OS::OVB::BaremetalNetworks: {{ templates_dir }}/baremetal-networks-all.yaml
{% endif %}

## Uncomment to use the neutron port-security extension to allow DHCP from
## the undercloud to overcloud nodes.  There are *-port-security.yaml versions
## of all the standard port resource templates.  The examples below are to use
## port-security with a minimal deployment (i.e. no network isolation).
#  OS::OVB::BaremetalPorts: templates/baremetal-ports-default-port-security.yaml
#  OS::OVB::BMCPort: templates/bmc-port-port-security.yaml
#  OS::OVB::UndercloudPorts: templates/undercloud-ports-port-security.yaml
{% if network_isolation_type in ['none', 'multi-nic', 'multiple-nics', 'public-bond'] and port_security|bool %}
  OS::OVB::BaremetalPorts: {{ templates_dir }}/{{ baremetal_port_security_template[network_isolation_type] }}
  OS::OVB::BMCPort: {{ templates_dir }}/bmc-port-port-security.yaml
  OS::OVB::UndercloudPorts: {{ templates_dir }}/undercloud-ports-port-security.yaml
{% endif %}

## Uncomment to deploy a quintupleo environment without an undercloud.
#  OS::OVB::UndercloudEnvironment: OS::Heat::None

# Boot from volume options
{% if boot_from_volume|bool %}
  OS::OVB::ServerPair: {{ templates_dir }}/virtual-baremetal-servers-volume.yaml
  OS::OVB::UndercloudEnvironment: {{ templates_dir }}/undercloud-volume.yaml
{% endif %}
