Force Ansible to use dynamic includes
Ansible 2.1.1 introduces a regression in the way conditional includes are handled which results in every task in the included file being evaluated even if the condition for the include is not met. This extends the run time significantly for a deployment. This patch forces all conditional includes to be dynamic. Change-Id: I72dabf1abace382f0b25499aaa56366a9baefa48 Related-Bug: https://github.com/ansible/ansible/issues/17687
This commit is contained in:
parent
988006d22d
commit
1f682b09ef
@ -14,6 +14,7 @@
|
||||
# limitations under the License.
|
||||
|
||||
- include: install-apt.yml
|
||||
static: no
|
||||
when:
|
||||
- ansible_pkg_mgr == 'apt'
|
||||
|
||||
|
@ -14,13 +14,13 @@
|
||||
# limitations under the License.
|
||||
|
||||
- include: horizon_ssl_key_create.yml
|
||||
when: >
|
||||
inventory_hostname == groups['horizon_all'][0]
|
||||
static: no
|
||||
when: inventory_hostname == groups['horizon_all'][0]
|
||||
|
||||
- include: horizon_ssl_key_store.yml
|
||||
when: >
|
||||
inventory_hostname == groups['horizon_all'][0]
|
||||
static: no
|
||||
when: inventory_hostname == groups['horizon_all'][0]
|
||||
|
||||
- include: horizon_ssl_key_distribute.yml
|
||||
when: >
|
||||
inventory_hostname != groups['horizon_all'][0]
|
||||
static: no
|
||||
when: inventory_hostname != groups['horizon_all'][0]
|
||||
|
@ -38,12 +38,13 @@
|
||||
- horizon-config
|
||||
|
||||
- include: horizon_db_setup.yml
|
||||
when: >
|
||||
inventory_hostname == groups['horizon_all'][0]
|
||||
static: no
|
||||
when: inventory_hostname == groups['horizon_all'][0]
|
||||
tags:
|
||||
- horizon-install
|
||||
|
||||
- include: horizon_ssl_self_signed.yml
|
||||
static: no
|
||||
when:
|
||||
- not horizon_external_ssl|bool
|
||||
- horizon_user_ssl_cert is not defined or horizon_user_ssl_key is not defined
|
||||
@ -51,6 +52,7 @@
|
||||
- horizon-install
|
||||
|
||||
- include: horizon_ssl_user_provided.yml
|
||||
static: no
|
||||
when: not horizon_external_ssl|bool
|
||||
tags:
|
||||
- horizon-install
|
||||
|
@ -18,6 +18,10 @@
|
||||
src: https://git.openstack.org/openstack/openstack-ansible-lxc_container_create
|
||||
scm: git
|
||||
version: master
|
||||
- name: openstack_hosts
|
||||
src: https://git.openstack.org/openstack/openstack-ansible-openstack_hosts
|
||||
scm: git
|
||||
version: master
|
||||
- name: lxc_hosts
|
||||
src: https://git.openstack.org/openstack/openstack-ansible-lxc_hosts
|
||||
scm: git
|
||||
|
Loading…
Reference in New Issue
Block a user