Merge "Define condition for the first play host one time"
This commit is contained in:
commit
d2409627d1
@ -71,8 +71,7 @@
|
|||||||
|
|
||||||
- import_tasks: db_setup.yml
|
- import_tasks: db_setup.yml
|
||||||
when:
|
when:
|
||||||
- "nova_services['nova-conductor']['group'] in group_names"
|
- _nova_is_first_play_host
|
||||||
- "inventory_hostname == ((groups[nova_services['nova-conductor']['group']] | intersect(ansible_play_hosts)) | list)[0]"
|
|
||||||
vars:
|
vars:
|
||||||
_oslodb_setup_host: "{{ nova_db_setup_host }}"
|
_oslodb_setup_host: "{{ nova_db_setup_host }}"
|
||||||
_oslodb_ansible_python_interpreter: "{{ nova_db_setup_python_interpreter }}"
|
_oslodb_ansible_python_interpreter: "{{ nova_db_setup_python_interpreter }}"
|
||||||
@ -97,8 +96,7 @@
|
|||||||
|
|
||||||
- import_tasks: mq_setup.yml
|
- import_tasks: mq_setup.yml
|
||||||
when:
|
when:
|
||||||
- "nova_services['nova-conductor']['group'] in group_names"
|
- _nova_is_first_play_host
|
||||||
- "inventory_hostname == ((groups[nova_services['nova-conductor']['group']] | intersect(ansible_play_hosts)) | list)[0]"
|
|
||||||
vars:
|
vars:
|
||||||
_oslomsg_rpc_setup_host: "{{ nova_oslomsg_rpc_setup_host }}"
|
_oslomsg_rpc_setup_host: "{{ nova_oslomsg_rpc_setup_host }}"
|
||||||
_oslomsg_rpc_userid: "{{ nova_oslomsg_rpc_userid }}"
|
_oslomsg_rpc_userid: "{{ nova_oslomsg_rpc_userid }}"
|
||||||
@ -172,15 +170,13 @@
|
|||||||
type: "{{ nova_service_type }}"
|
type: "{{ nova_service_type }}"
|
||||||
description: "{{ nova_service_description }}"
|
description: "{{ nova_service_description }}"
|
||||||
when:
|
when:
|
||||||
- "nova_services['nova-conductor']['group'] in group_names"
|
- _nova_is_first_play_host
|
||||||
- "inventory_hostname == ((groups['nova_conductor'] | intersect(ansible_play_hosts)) | list)[0]"
|
|
||||||
tags:
|
tags:
|
||||||
- nova-config
|
- nova-config
|
||||||
|
|
||||||
- import_tasks: nova_db_setup.yml
|
- import_tasks: nova_db_setup.yml
|
||||||
when:
|
when:
|
||||||
- "nova_services['nova-conductor']['group'] in group_names"
|
- _nova_is_first_play_host
|
||||||
- "inventory_hostname == ((groups['nova_conductor'] | intersect(ansible_play_hosts)) | list)[0]"
|
|
||||||
tags:
|
tags:
|
||||||
- nova-config
|
- nova-config
|
||||||
|
|
||||||
|
@ -13,6 +13,8 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
_nova_is_first_play_host: "{{ (nova_services['nova-conductor']['group'] in group_names and inventory_hostname == (groups[nova_services['nova-conductor']['group']] | intersect(ansible_play_hosts)) | first) | bool }}"
|
||||||
|
|
||||||
nova_venv_packages: |-
|
nova_venv_packages: |-
|
||||||
{%- set pkg_list = nova_pip_packages | union(nova_user_pip_packages) %}
|
{%- set pkg_list = nova_pip_packages | union(nova_user_pip_packages) %}
|
||||||
{%- if nova_oslomsg_amqp1_enabled | bool %}
|
{%- if nova_oslomsg_amqp1_enabled | bool %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user