VOL-394 This update ensures that the appropriate directories are created
for consul and that the consul config is copied to one of those
directories.
Change-Id: I3f925f1ee28786fe4f9acdb54bbbe0db6b708857
diff --git a/install/ansible/roles/cluster-host/tasks/main.yml b/install/ansible/roles/cluster-host/tasks/main.yml
index ac1e2e2..17bcd43 100644
--- a/install/ansible/roles/cluster-host/tasks/main.yml
+++ b/install/ansible/roles/cluster-host/tasks/main.yml
@@ -183,23 +183,17 @@
when: target == "cluster"
tags: [cluster_host]
-- name: A directory for the insecure registry data is created
+- name: Directories for voltha processes are created
file:
- path: "{{ target_voltha_dir }}/registry_data"
+ path: "{{ target_voltha_dir }}/{{ item }}"
state: directory
mode: 0755
owner: voltha
group: voltha
- when: target == "cluster"
- tags: [cluster_host]
-
-- name: A directory for consul's data is created
- file:
- path: "{{ target_voltha_dir }}/consul/data"
- state: directory
- mode: 0755
- owner: voltha
- group: voltha
+ with_items:
+ - registry_data
+ - consul/data
+ - consul/config
when: target == "cluster"
tags: [cluster_host]