Merge "Check host group_names for group membership"
This commit is contained in:
commit
fa17da701d
@ -63,20 +63,22 @@
|
||||
- neutron-install
|
||||
|
||||
- include: neutron_db_setup.yml
|
||||
when: >
|
||||
inventory_hostname == groups[neutron_services['neutron-server']['group']][0]
|
||||
when:
|
||||
- neutron_services['neutron-server']['group'] in group_names
|
||||
- inventory_hostname == groups[neutron_services['neutron-server']['group']][0]
|
||||
tags:
|
||||
- neutron-install
|
||||
|
||||
- include: neutron_service_setup.yml
|
||||
when: >
|
||||
inventory_hostname == groups['neutron_all'][0]
|
||||
when:
|
||||
- "'neutron_all' in group_names"
|
||||
- inventory_hostname == groups['neutron_all'][0]
|
||||
tags:
|
||||
- neutron-install
|
||||
|
||||
- include: neutron_l3_ha.yml
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-l3-agent']['group']]
|
||||
- neutron_services['neutron-l3-agent']['group'] in group_names
|
||||
- neutron_legacy_ha_tool_enabled | bool
|
||||
|
||||
- name: Flush handlers
|
||||
|
@ -22,7 +22,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-server']['group']]
|
||||
- neutron_services['neutron-server']['group'] in group_names
|
||||
- neutron_services['neutron-server'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -34,7 +34,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-dhcp-agent']['group']]
|
||||
- neutron_services['neutron-dhcp-agent']['group'] in group_names
|
||||
- neutron_services['neutron-dhcp-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -46,7 +46,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-l3-agent']['group']]
|
||||
- neutron_services['neutron-l3-agent']['group'] in group_names
|
||||
- neutron_services['neutron-l3-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -58,7 +58,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-linuxbridge-agent']['group']]
|
||||
- neutron_services['neutron-linuxbridge-agent']['group'] in group_names
|
||||
- neutron_services['neutron-linuxbridge-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -71,7 +71,6 @@
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- neutron_services['neutron-openvswitch-agent']['group'] in group_names
|
||||
- inventory_hostname in groups[neutron_services['neutron-openvswitch-agent']['group']]
|
||||
- neutron_services['neutron-openvswitch-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -83,7 +82,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-metadata-agent']['group']]
|
||||
- neutron_services['neutron-metadata-agent']['group'] in group_names
|
||||
- neutron_services['neutron-metadata-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -95,7 +94,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-metering-agent']['group']]
|
||||
- neutron_services['neutron-metering-agent']['group'] in group_names
|
||||
- neutron_services['neutron-metering-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -107,7 +106,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-lbaas-agent']['group']]
|
||||
- neutron_services['neutron-lbaas-agent']['group'] in group_names
|
||||
- neutron_services['neutron-lbaas-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -119,7 +118,7 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-lbaasv2-agent']['group']]
|
||||
- neutron_services['neutron-lbaasv2-agent']['group'] in group_names
|
||||
- neutron_services['neutron-lbaasv2-agent'].service_en | bool
|
||||
|
||||
- include: neutron_init_common.yml
|
||||
@ -131,5 +130,5 @@
|
||||
system_group: "{{ neutron_system_group_name }}"
|
||||
service_home: "{{ neutron_system_home_folder }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-vpnaas-agent']['group']]
|
||||
- neutron_services['neutron-vpnaas-agent']['group'] in group_names
|
||||
- neutron_services['neutron-vpnaas-agent'].service_en | bool
|
||||
|
@ -61,7 +61,6 @@
|
||||
delay: 2
|
||||
with_items: "{{ neutron_lxb_apt_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-linuxbridge-agent']['group']]
|
||||
- neutron_services['neutron-linuxbridge-agent']['group'] in group_names
|
||||
- neutron_services['neutron-linuxbridge-agent'].service_en | bool
|
||||
|
||||
@ -75,7 +74,6 @@
|
||||
delay: 2
|
||||
with_items: "{{ ovs_apt_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-openvswitch-agent']['group']]
|
||||
- neutron_services['neutron-openvswitch-agent']['group'] in group_names
|
||||
- neutron_services['neutron-openvswitch-agent'].service_en | bool
|
||||
|
||||
@ -89,7 +87,7 @@
|
||||
delay: 2
|
||||
with_items: "{{ neutron_lbaas_apt_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-lbaas-agent']['group']]
|
||||
- neutron_services['neutron-lbaas-agent']['group'] in group_names
|
||||
- neutron_lbaas | bool or neutron_lbaasv2 | bool
|
||||
|
||||
- name: Install apt packages for VPNaaS
|
||||
@ -102,7 +100,7 @@
|
||||
delay: 2
|
||||
with_items: "{{ neutron_vpnaas_apt_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-vpnaas-agent']['group']]
|
||||
- neutron_services['neutron-vpnaas-agent']['group'] in group_names
|
||||
- neutron_vpnaas | bool
|
||||
|
||||
- name: remove specific apt packages
|
||||
|
@ -60,7 +60,7 @@
|
||||
notify:
|
||||
- Restart neutron services
|
||||
when: >
|
||||
inventory_hostname in groups[neutron_services['neutron-dhcp-agent']['group']]
|
||||
neutron_services['neutron-dhcp-agent']['group'] in group_names
|
||||
|
||||
- name: Generate neutron agent only Config
|
||||
config_template:
|
||||
@ -77,7 +77,7 @@
|
||||
when:
|
||||
- item.value.service_en | bool
|
||||
- item.value.service_conf is defined
|
||||
- inventory_hostname in groups[item.value.group]
|
||||
- item.value.group in group_names
|
||||
|
||||
- name: Drop neutron rootwrap filters
|
||||
copy:
|
||||
@ -129,10 +129,10 @@
|
||||
mode: "0755"
|
||||
when:
|
||||
- neutron_metadata_checksum_fix | bool
|
||||
- inventory_hostname in groups[neutron_services['neutron-linuxbridge-agent']['group']]
|
||||
- neutron_services['neutron-linuxbridge-agent']['group'] in group_names
|
||||
|
||||
- name: Run metadata iptables checksum fix
|
||||
command: /etc/network/if-up.d/post-up-metadata-checksum
|
||||
when:
|
||||
- neutron_metadata_checksum_fix | bool
|
||||
- inventory_hostname in groups[neutron_services['neutron-linuxbridge-agent']['group']]
|
||||
- neutron_services['neutron-linuxbridge-agent']['group'] in group_names
|
||||
|
@ -23,4 +23,4 @@
|
||||
with_items:
|
||||
- "{{ neutron_proprietary_nuage_pip_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-server']['group']]
|
||||
- neutron_services['neutron-server']['group'] in group_names
|
||||
|
@ -43,7 +43,7 @@
|
||||
with_items:
|
||||
- "{{ neutron_optional_plumgrid_pip_packages }}"
|
||||
when:
|
||||
- inventory_hostname in groups[neutron_services['neutron-server']['group']]
|
||||
- neutron_services['neutron-server']['group'] in group_names
|
||||
|
||||
- name: Install plumgrid pip packages fall back
|
||||
pip:
|
||||
@ -60,4 +60,4 @@
|
||||
- "{{ neutron_optional_plumgrid_pip_packages }}"
|
||||
when:
|
||||
- install_packages | failed
|
||||
- inventory_hostname in groups[neutron_services['neutron-server']['group']]
|
||||
- neutron_services['neutron-server']['group'] in group_names
|
||||
|
@ -9,7 +9,7 @@ debug = {{ debug }}
|
||||
fatal_deprecations = {{ neutron_fatal_deprecations }}
|
||||
log_file = /var/log/neutron/neutron.log
|
||||
|
||||
{% if inventory_hostname in groups[neutron_services['neutron-server']['group']] %}
|
||||
{% if neutron_services['neutron-server']['group'] in group_names %}
|
||||
|
||||
# General, only applies to neutron server host group
|
||||
allow_overlapping_ips = True
|
||||
|
Loading…
Reference in New Issue
Block a user