---

# NOTE(hrybacki): This is a hotfix to be removed after
# https://review.openstack.org/#/c/414167/ has been merged.

validation_args: ""

control_memory: 16384
control_vcpu: 4

# Define single controller node with two computes to allow for scaling
overcloud_nodes:
  - name: control_0
    flavor: control
    virtualbmc_port: 6230

  - name: compute_0
    flavor: compute
    virtualbmc_port: 6231

  - name: compute_1
    flavor: compute
    virtualbmc_port: 6232

# If `run_tempest` is `true`, run tempests tests, otherwise do not
# run them.
run_tempest: false
tempest_config: false
enable_pacemaker: true
network_isolation: true
network_isolation_type: 'single-nic-vlans'
deploy_timeout: 75

# General deployment info
libvirt_args: "--libvirt-type qemu"

flavor_args: >-
  --control-flavor {{flavor_map.control
  if flavor_map is defined and 'control' in flavor_map else 'oooq_control'}}
  --compute-flavor {{flavor_map.compute
  if flavor_map is defined and 'compute' in flavor_map else 'oooq_compute'}}

timeout_args: "--timeout {{ deploy_timeout }}"

extra_args: >
  --compute-scale 1
  -e {{ overcloud_templates_path }}/environments/network-isolation.yaml
  -e {{ overcloud_templates_path }}/environments/net-single-nic-with-vlans.yaml
  -e ~/network-environment.yaml --ntp-server pool.ntp.org

# Pull out scale_extra_args so the same var can be reused for the call to
# `openstack overcloud delete`
scale_extra_configs: >
  -e {{ overcloud_templates_path }}/environments/network-isolation.yaml
  -e {{ overcloud_templates_path }}/environments/net-single-nic-with-vlans.yaml
  -e /home/stack/network-environment.yaml
scale_extra_args: >
  --{{ node_to_scale }}-scale {{ final_scale_value }} {{ scale_extra_configs }}
  --ntp-server pool.ntp.org

# Scale deployment info
node_to_scale: compute  # Type of node to scale
initial_scale_value: 1  # Initial number of nodes to deploy
final_scale_value: 2  # Number of additional nodes to add during the scale

# Scale deployment arguments
scale_args: >-
  {{ libvirt_args }}
  {{ flavor_args }}
  {{ timeout_args }}
  {{ pacemaker_args }}
  {{ scale_extra_args }}

# Options below direct automatic doc generation by collect-logs
artcl_gen_docs: true
artcl_create_docs_payload:
  included_deployment_scripts:
    - undercloud-install
    - overcloud-custom-tht-script
    - overcloud-prep-flavors
    - overcloud-prep-images
    - overcloud-prep-network
    - overcloud-deploy
    - overcloud-deploy-post
    - overcloud-validate
    - scale-deployment
    - delete-node
  included_static_docs:
    - env-setup-virt
  table_of_contents:
    - env-setup-virt
    - undercloud-install
    - overcloud-custom-tht-script
    - overcloud-prep-flavors
    - overcloud-prep-images
    - overcloud-prep-network
    - overcloud-deploy
    - overcloud-deploy-post
    - overcloud-validate
    - scale-deployment
    - delete-node
    - overcloud-validate

# Path to tripleo-heat-templates
overcloud_templates_path: /usr/share/openstack-tripleo-heat-templates

# Sample call
# ./deploy.sh -v --playbook scale_nodes --config-file config/scale/scale_compute.yml
