From 157dc0f177ea3f4ff1901de37f9d17d183d6cb12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Maty=C3=A1=C5=A1?= Date: Tue, 4 Oct 2016 08:04:57 -0700 Subject: [PATCH] Make iscsi config.yml consistent with start.yml As part of non-lvm iscsi bugfix, changes were introduced to iscsi's start.yml. Same changes/conditions should be reflected to config.yml so container configuration is deployed on the same nodes as containers are started. TrivialFix Change-Id: Ib988df2d36983d63a3aff4226224dc5fc6064221 --- ansible/roles/iscsi/tasks/config.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ansible/roles/iscsi/tasks/config.yml b/ansible/roles/iscsi/tasks/config.yml index 4393db15f5..0ebe3dd745 100644 --- a/ansible/roles/iscsi/tasks/config.yml +++ b/ansible/roles/iscsi/tasks/config.yml @@ -23,7 +23,9 @@ path: "{{ node_config_directory }}/{{ item }}" state: "directory" recurse: yes - when: inventory_hostname in groups['tgtd'] + when: + - inventory_hostname in groups['tgtd'] + - enable_cinder_backend_lvm | bool with_items: - "tgtd" @@ -31,6 +33,8 @@ template: src: "{{ item }}.json.j2" dest: "{{ node_config_directory }}/{{ item }}/config.json" - when: inventory_hostname in groups['tgtd'] + when: + - inventory_hostname in groups['tgtd'] + - enable_cinder_backend_lvm | bool with_items: - "tgtd"