diff --git a/ansible/compute-node-discovery.yml b/ansible/compute-node-discovery.yml index 6dbc11612..9a84aefcb 100644 --- a/ansible/compute-node-discovery.yml +++ b/ansible/compute-node-discovery.yml @@ -1,5 +1,5 @@ --- -- include: dell-compute-node-inventory.yml +- import_playbook: dell-compute-node-inventory.yml - name: Ensure baremetal compute nodes are PXE booted hosts: baremetal-compute diff --git a/ansible/dell-compute-node-boot-mode.yml b/ansible/dell-compute-node-boot-mode.yml index bddbe57f7..67152a37d 100644 --- a/ansible/dell-compute-node-boot-mode.yml +++ b/ansible/dell-compute-node-boot-mode.yml @@ -2,7 +2,7 @@ # Set the boot mode (BIOS, UEFI) of Dell baremetal compute nodes. # Add Dell baremetal compute nodes to the Ansible inventory. -- include: dell-compute-node-inventory.yml +- import_playbook: dell-compute-node-inventory.yml - name: Ensure Dell baremetal compute nodes boot mode is set hosts: baremetal-compute diff --git a/ansible/dell-compute-node-discovery.yml b/ansible/dell-compute-node-discovery.yml index 9cf26cc4b..683659444 100644 --- a/ansible/dell-compute-node-discovery.yml +++ b/ansible/dell-compute-node-discovery.yml @@ -2,7 +2,7 @@ # Configure the Dell baremetal compute nodes to PXE boot. # Add Dell baremetal compute nodes to the Ansible inventory. -- include: dell-compute-node-inventory.yml +- import_playbook: dell-compute-node-inventory.yml - name: Ensure Dell baremetal compute nodes are PXE booted hosts: baremetal-compute diff --git a/ansible/idrac-bootstrap.yml b/ansible/idrac-bootstrap.yml index 6001e5011..17c28a177 100644 --- a/ansible/idrac-bootstrap.yml +++ b/ansible/idrac-bootstrap.yml @@ -142,7 +142,7 @@ # Iterate over each switch port with an iDRAC attached in turn. - name: Ensure iDRACs are (sequentially) bootstrapped - include: idrac-bootstrap-one.yml + include_tasks: idrac-bootstrap-one.yml vars: dell_switch_type: "{{ switch_type }}" dell_switch_provider: "{{ switch_dellos_provider }}" diff --git a/ansible/overcloud-extras.yml b/ansible/overcloud-extras.yml index 453abae5b..4993ce0de 100644 --- a/ansible/overcloud-extras.yml +++ b/ansible/overcloud-extras.yml @@ -7,8 +7,8 @@ # Variables: # action: One of deploy, destroy, pull, reconfigure, upgrade -- include: docker-registry.yml -- include: inspection-store.yml -- include: opensm.yml -- include: node-exporter.yml -- include: cadvisor.yml +- import_playbook: docker-registry.yml +- import_playbook: inspection-store.yml +- import_playbook: opensm.yml +- import_playbook: node-exporter.yml +- import_playbook: cadvisor.yml diff --git a/ansible/roles/cadvisor/tasks/main.yml b/ansible/roles/cadvisor/tasks/main.yml index 8c58a92d9..f14cbb59b 100644 --- a/ansible/roles/cadvisor/tasks/main.yml +++ b/ansible/roles/cadvisor/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ cadvisor_action }}.yml" +- include_tasks: "{{ cadvisor_action }}.yml" diff --git a/ansible/roles/cadvisor/tasks/upgrade.yml b/ansible/roles/cadvisor/tasks/upgrade.yml index 8459b03ca..99348ae91 100644 --- a/ansible/roles/cadvisor/tasks/upgrade.yml +++ b/ansible/roles/cadvisor/tasks/upgrade.yml @@ -1,3 +1,3 @@ --- -- include: pull.yml -- include: deploy.yml +- include_tasks: pull.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/docker-registry/tasks/main.yml b/ansible/roles/docker-registry/tasks/main.yml index 8b3c80e88..98843464f 100644 --- a/ansible/roles/docker-registry/tasks/main.yml +++ b/ansible/roles/docker-registry/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ docker_registry_action }}.yml" +- include_tasks: "{{ docker_registry_action }}.yml" diff --git a/ansible/roles/docker-registry/tasks/upgrade.yml b/ansible/roles/docker-registry/tasks/upgrade.yml index 8459b03ca..99348ae91 100644 --- a/ansible/roles/docker-registry/tasks/upgrade.yml +++ b/ansible/roles/docker-registry/tasks/upgrade.yml @@ -1,3 +1,3 @@ --- -- include: pull.yml -- include: deploy.yml +- include_tasks: pull.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/docker/tasks/main.yml b/ansible/roles/docker/tasks/main.yml index 4fa1a0291..242eb0459 100644 --- a/ansible/roles/docker/tasks/main.yml +++ b/ansible/roles/docker/tasks/main.yml @@ -78,7 +78,7 @@ - "'Data loop file' in docker_info.stdout or docker_storage_driver not in docker_info.stdout" - "'Images: 0' not in docker_info.stdout or 'Containers: 0' not in docker_info.stdout" -- include: storage.yml +- include_tasks: storage.yml when: "'Data loop file' in docker_info.stdout or docker_storage_driver not in docker_info.stdout" -- include: config.yml +- include_tasks: config.yml diff --git a/ansible/roles/inspection-store/tasks/deploy.yml b/ansible/roles/inspection-store/tasks/deploy.yml index 65966076b..d1f8db5d8 100644 --- a/ansible/roles/inspection-store/tasks/deploy.yml +++ b/ansible/roles/inspection-store/tasks/deploy.yml @@ -1,3 +1,3 @@ --- -- include: config.yml -- include: start.yml +- include_tasks: config.yml +- include_tasks: start.yml diff --git a/ansible/roles/inspection-store/tasks/main.yml b/ansible/roles/inspection-store/tasks/main.yml index 47165bf07..23541719d 100644 --- a/ansible/roles/inspection-store/tasks/main.yml +++ b/ansible/roles/inspection-store/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ inspection_store_action }}.yml" +- include_tasks: "{{ inspection_store_action }}.yml" diff --git a/ansible/roles/inspection-store/tasks/reconfigure.yml b/ansible/roles/inspection-store/tasks/reconfigure.yml index e078ef131..f670a5b78 100644 --- a/ansible/roles/inspection-store/tasks/reconfigure.yml +++ b/ansible/roles/inspection-store/tasks/reconfigure.yml @@ -1,2 +1,2 @@ --- -- include: deploy.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/inspection-store/tasks/upgrade.yml b/ansible/roles/inspection-store/tasks/upgrade.yml index 8459b03ca..99348ae91 100644 --- a/ansible/roles/inspection-store/tasks/upgrade.yml +++ b/ansible/roles/inspection-store/tasks/upgrade.yml @@ -1,3 +1,3 @@ --- -- include: pull.yml -- include: deploy.yml +- include_tasks: pull.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/kolla-ansible/tasks/main.yml b/ansible/roles/kolla-ansible/tasks/main.yml index 969f7a192..031f38a97 100644 --- a/ansible/roles/kolla-ansible/tasks/main.yml +++ b/ansible/roles/kolla-ansible/tasks/main.yml @@ -1,8 +1,10 @@ --- -- include: install.yml +# NOTE: Use import_tasks here, since tags are not applied to tasks included via +# include_tasks. +- import_tasks: install.yml tags: - install -- include: config.yml +- import_tasks: config.yml tags: - config diff --git a/ansible/roles/kolla-ansible/tests/main.yml b/ansible/roles/kolla-ansible/tests/main.yml index 1451fa324..8347fa49c 100644 --- a/ansible/roles/kolla-ansible/tests/main.yml +++ b/ansible/roles/kolla-ansible/tests/main.yml @@ -6,9 +6,9 @@ # - Pass through variables # - Nova ironic compute host -- include: test-defaults.yml -- include: test-extras.yml -- include: test-requirements.yml +- import_playbook: test-defaults.yml +- import_playbook: test-extras.yml +- import_playbook: test-requirements.yml - hosts: localhost connection: local diff --git a/ansible/roles/kolla-ceph/tasks/main.yml b/ansible/roles/kolla-ceph/tasks/main.yml index 0079f60ce..5739e64d0 100644 --- a/ansible/roles/kolla-ceph/tasks/main.yml +++ b/ansible/roles/kolla-ceph/tasks/main.yml @@ -1,4 +1,6 @@ --- -- include: config.yml +# NOTE: Use import_tasks here, since tags are not applied to tasks included via +# include_tasks. +- import_tasks: config.yml tags: - config diff --git a/ansible/roles/kolla-ceph/tests/main.yml b/ansible/roles/kolla-ceph/tests/main.yml index 97e8ab4f2..49b8afae1 100644 --- a/ansible/roles/kolla-ceph/tests/main.yml +++ b/ansible/roles/kolla-ceph/tests/main.yml @@ -1,8 +1,8 @@ --- -- include: test-no-journal.yml -- include: test-journal.yml -- include: test-bootstrapped-journal.yml -- include: test-data-journal.yml +- import_playbook: test-no-journal.yml +- import_playbook: test-journal.yml +- import_playbook: test-bootstrapped-journal.yml +- import_playbook: test-data-journal.yml - hosts: localhost connection: local diff --git a/ansible/roles/kolla-openstack/tasks/main.yml b/ansible/roles/kolla-openstack/tasks/main.yml index 0079f60ce..5739e64d0 100644 --- a/ansible/roles/kolla-openstack/tasks/main.yml +++ b/ansible/roles/kolla-openstack/tasks/main.yml @@ -1,4 +1,6 @@ --- -- include: config.yml +# NOTE: Use import_tasks here, since tags are not applied to tasks included via +# include_tasks. +- import_tasks: config.yml tags: - config diff --git a/ansible/roles/kolla/tasks/main.yml b/ansible/roles/kolla/tasks/main.yml index 969f7a192..031f38a97 100644 --- a/ansible/roles/kolla/tasks/main.yml +++ b/ansible/roles/kolla/tasks/main.yml @@ -1,8 +1,10 @@ --- -- include: install.yml +# NOTE: Use import_tasks here, since tags are not applied to tasks included via +# include_tasks. +- import_tasks: install.yml tags: - install -- include: config.yml +- import_tasks: config.yml tags: - config diff --git a/ansible/roles/node-exporter/tasks/main.yml b/ansible/roles/node-exporter/tasks/main.yml index 4fdd4df70..bb8e0094c 100644 --- a/ansible/roles/node-exporter/tasks/main.yml +++ b/ansible/roles/node-exporter/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ nodeexporter_action }}.yml" +- include_tasks: "{{ nodeexporter_action }}.yml" diff --git a/ansible/roles/node-exporter/tasks/upgrade.yml b/ansible/roles/node-exporter/tasks/upgrade.yml index 8459b03ca..99348ae91 100644 --- a/ansible/roles/node-exporter/tasks/upgrade.yml +++ b/ansible/roles/node-exporter/tasks/upgrade.yml @@ -1,3 +1,3 @@ --- -- include: pull.yml -- include: deploy.yml +- include_tasks: pull.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/opensm/tasks/main.yml b/ansible/roles/opensm/tasks/main.yml index 931d389c8..31d688d6a 100644 --- a/ansible/roles/opensm/tasks/main.yml +++ b/ansible/roles/opensm/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ opensm_action }}.yml" +- include_tasks: "{{ opensm_action }}.yml" diff --git a/ansible/roles/opensm/tasks/upgrade.yml b/ansible/roles/opensm/tasks/upgrade.yml index 8459b03ca..99348ae91 100644 --- a/ansible/roles/opensm/tasks/upgrade.yml +++ b/ansible/roles/opensm/tasks/upgrade.yml @@ -1,3 +1,3 @@ --- -- include: pull.yml -- include: deploy.yml +- include_tasks: pull.yml +- include_tasks: deploy.yml diff --git a/ansible/roles/swift-setup/tasks/main.yml b/ansible/roles/swift-setup/tasks/main.yml index f342e69bb..2927dab7d 100644 --- a/ansible/roles/swift-setup/tasks/main.yml +++ b/ansible/roles/swift-setup/tasks/main.yml @@ -1,3 +1,3 @@ --- -- include: devices.yml -- include: rings.yml +- include_tasks: devices.yml +- include_tasks: rings.yml diff --git a/ansible/roles/yum/tasks/main.yml b/ansible/roles/yum/tasks/main.yml index a27a33a72..25a170709 100644 --- a/ansible/roles/yum/tasks/main.yml +++ b/ansible/roles/yum/tasks/main.yml @@ -1,7 +1,7 @@ --- - block: - - include: redhat.yml + - include_tasks: redhat.yml when: yum_use_local_mirror | bool - - include: custom_repo.yml + - include_tasks: custom_repo.yml when: ansible_os_family == 'RedHat' diff --git a/roles/kayobe-diagnostics/tasks/main.yml b/roles/kayobe-diagnostics/tasks/main.yml index 8cc20231b..22a602729 100644 --- a/roles/kayobe-diagnostics/tasks/main.yml +++ b/roles/kayobe-diagnostics/tasks/main.yml @@ -1,2 +1,2 @@ --- -- include: "{{ kayobe_diagnostics_phase }}.yml" +- include_tasks: "{{ kayobe_diagnostics_phase }}.yml"