From dfce6dba6ed9922f180988413ca414df52287272 Mon Sep 17 00:00:00 2001 From: Mohammed Naser Date: Fri, 2 Nov 2018 18:48:40 +0100 Subject: [PATCH] Refactor pre-install checks into neutron_check.yml Change-Id: I213cc4771ad0a1b71d4b03c779f19ac42a73205a --- tasks/main.yml | 10 ---------- tasks/neutron_check.yml | 10 ++++++++++ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tasks/main.yml b/tasks/main.yml index 6919d66a..33616370 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -27,16 +27,6 @@ tags: - always -- name: Fail if service was deployed using a different installation method - fail: - msg: "Switching installation methods for OpenStack services is not supported" - when: - - ansible_local is defined - - ansible_local.openstack_ansible is defined - - ansible_local.openstack_ansible.neutron is defined - - ansible_local.openstack_ansible.neutron.install_method is defined - - ansible_local.openstack_ansible.neutron.install_method != neutron_install_method - - name: Gather variables for installation method include_vars: "{{ neutron_install_method }}_install.yml" tags: diff --git a/tasks/neutron_check.yml b/tasks/neutron_check.yml index f646c889..a426be08 100644 --- a/tasks/neutron_check.yml +++ b/tasks/neutron_check.yml @@ -21,3 +21,13 @@ when: - neutron_fwaas | bool - neutron_fwaas_v2 | bool + +- name: Fail if service was deployed using a different installation method + fail: + msg: "Switching installation methods for OpenStack services is not supported" + when: + - ansible_local is defined + - ansible_local.openstack_ansible is defined + - ansible_local.openstack_ansible.neutron is defined + - ansible_local.openstack_ansible.neutron.install_method is defined + - ansible_local.openstack_ansible.neutron.install_method != neutron_install_method \ No newline at end of file