This patch enables availability zone reselected by stack retry when "instantiate" "scale" "heal" operations in v2 API fails due to availability zone is unavailable. Note that precondition of using these functions is to use StandardUserData as UserData class. Implements: blueprint enhance-placement Change-Id: Icc9eb7a8fffbf35d2e005a9703dcefe66f097584
21 lines
798 B
YAML
21 lines
798 B
YAML
- block:
|
|
- name: Create OpenStack availability zone
|
|
shell: |
|
|
openstack --os-cloud devstack-admin aggregate create \
|
|
{{ aggregate_name }}
|
|
openstack --os-cloud devstack-admin aggregate set \
|
|
--zone {{ zone_name }} {{ aggregate_name }}
|
|
openstack --os-cloud devstack-admin aggregate add host \
|
|
{{ aggregate_name }} {{ controller_tacker_hostname }}
|
|
|
|
# NOTE: This flavor is used for testing to check that VNFc is created
|
|
# in other zones due to lack of zone resources.
|
|
# Therefore, it is necessary to create this flavor with large memory.
|
|
- name: Create OpenStack flavor
|
|
shell: |
|
|
openstack --os-cloud devstack-admin \
|
|
flavor create --ram 4096 --disk 4 --vcpus 2 {{ flavor_name }}
|
|
|
|
when:
|
|
- inventory_hostname == 'controller'
|