blob: 782a151af710f10aea450ce7c27b490819178023 [file] [log] [blame]
Sergio Slobodrian8725ea82017-08-27 23:47:41 -04001- name: The glusterfs registry volume is created
Sergio Slobodrian523ee782017-08-22 16:44:21 -04002 gluster_volume:
Sergio Slobodrian8725ea82017-08-27 23:47:41 -04003 bricks: "{{ barrier_fs_dir }}/reg_brick1"
Sergio Slobodrian523ee782017-08-22 16:44:21 -04004 force: true
5 cluster: "{{groups.cluster | join(\",\")}}"
6 replicas: 3
7 name: registry_volume
8 state: present
9 run_once: true
10
Sergio Slobodrian8725ea82017-08-27 23:47:41 -040011- name: The glusterfs logging volume is created
Sergio Slobodrian523ee782017-08-22 16:44:21 -040012 gluster_volume:
Sergio Slobodrian8725ea82017-08-27 23:47:41 -040013 bricks: "{{ barrier_fs_dir }}/log_brick1"
14 force: true
15 cluster: "{{groups.cluster | join(\",\")}}"
16 disperses: 3
17 name: logging_volume
18 state: present
19 run_once: true
20
21- name: Start the gluster volumes
22 gluster_volume:
23 name: "{{ item }}"
Sergio Slobodrian523ee782017-08-22 16:44:21 -040024 state: started
Sergio Slobodrian8725ea82017-08-27 23:47:41 -040025 with_items:
26 - registry_volume
27 - logging_volume
28
Stephane Barbarie2cbffca2018-03-26 16:20:03 -040029- name: The replicated registry filesystem is mounted
30 mount:
31 path: "{{ target_voltha_dir }}/registry_data"
32 src: "{{ inventory_hostname }}:/registry_volume"
33 fstype: glusterfs
34 opts: "defaults,_netdev,noauto,x-systemd.automount"
35 state: mounted
36 when: target == "cluster"
37
38- name: The replicated logging filesystem is mounted on boot
39 mount:
40 path: "/var/log/voltha"
41 src: "{{ inventory_hostname }}:/logging_volume"
42 fstype: glusterfs
43 opts: "defaults,_netdev,noauto,x-systemd.automount"
44 state: mounted
45 when: target == "cluster"
46 tags: [cluster_host]