From b60abe9573a7766dc256aa462679ae45cf7ea233 Mon Sep 17 00:00:00 2001 From: caoyuan Date: Tue, 24 Jul 2018 18:58:48 +0800 Subject: [PATCH] use include_tasks instead of include include is marked as deprecated since ansible 2.4[0] Switch to include_tasks or import_playbook as necessary [0] https://docs.ansible.com/ansible/2.4/include_module.html#deprecated Change-Id: I969209a4205fac9e205439dc97a96ddf3ea53800 --- tasks/horizon_ssl_self_signed.yml | 6 +++--- tasks/main.yml | 18 +++++++++--------- tests/test.yml | 10 +++++----- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/tasks/horizon_ssl_self_signed.yml b/tasks/horizon_ssl_self_signed.yml index 0f7aecb9..a5fdad1d 100644 --- a/tasks/horizon_ssl_self_signed.yml +++ b/tasks/horizon_ssl_self_signed.yml @@ -13,11 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. -- include: horizon_ssl_key_create.yml +- include_tasks: horizon_ssl_key_create.yml when: inventory_hostname == groups['horizon_all'][0] -- include: horizon_ssl_key_store.yml +- include_tasks: horizon_ssl_key_store.yml when: inventory_hostname == groups['horizon_all'][0] -- include: horizon_ssl_key_distribute.yml +- include_tasks: horizon_ssl_key_distribute.yml when: inventory_hostname != groups['horizon_all'][0] diff --git a/tasks/main.yml b/tasks/main.yml index 38a6fdd2..c20a562f 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -39,25 +39,25 @@ tags: - always -- include: horizon_pre_install.yml +- include_tasks: horizon_pre_install.yml tags: - horizon-install -- include: horizon_install.yml +- include_tasks: horizon_install.yml tags: - horizon-install -- include: horizon_post_install.yml +- include_tasks: horizon_post_install.yml tags: - horizon-config -- include: horizon_db_setup.yml +- include_tasks: horizon_db_setup.yml static: no when: inventory_hostname == ansible_play_hosts[0] tags: - horizon-config -- include: horizon_ssl_self_signed.yml +- include_tasks: horizon_ssl_self_signed.yml static: no when: - not horizon_external_ssl | bool @@ -65,7 +65,7 @@ tags: - horizon-config -- include: horizon_ssl_user_provided.yml +- include_tasks: horizon_ssl_user_provided.yml static: no when: not horizon_external_ssl | bool tags: @@ -80,7 +80,7 @@ - horizon-config - horizon-ssl -- include: horizon_service_setup.yml +- include_tasks: horizon_service_setup.yml tags: - horizon-config @@ -114,11 +114,11 @@ tags: - horizon-config -- include: horizon_apache.yml +- include_tasks: horizon_apache.yml tags: - horizon-config -- include: horizon_translations_update.yml +- include_tasks: horizon_translations_update.yml when: horizon_translations_update | bool tags: - horizon-config diff --git a/tests/test.yml b/tests/test.yml index ab04a669..f2a2e81d 100644 --- a/tests/test.yml +++ b/tests/test.yml @@ -14,16 +14,16 @@ # limitations under the License. # Setup the host -- include: common/test-setup-host.yml +- import_playbook: common/test-setup-host.yml # Install RabbitMQ/MariaDB -- include: common/test-install-infra.yml +- import_playbook: common/test-install-infra.yml # Install Keystone -- include: common/test-install-keystone.yml +- import_playbook: common/test-install-keystone.yml # Install Horizon -- include: common/test-install-horizon.yml +- import_playbook: common/test-install-horizon.yml # Install and execute Tempest -- include: common/test-install-tempest.yml +- import_playbook: common/test-install-tempest.yml