summaryrefslogtreecommitdiffstats
path: root/ansible/node/roles/storage
diff options
context:
space:
mode:
Diffstat (limited to 'ansible/node/roles/storage')
-rw-r--r--ansible/node/roles/storage/tasks/generic/clusterfs-glusterfs.yml8
-rw-r--r--ansible/node/roles/storage/vars/main.yml44
2 files changed, 52 insertions, 0 deletions
diff --git a/ansible/node/roles/storage/tasks/generic/clusterfs-glusterfs.yml b/ansible/node/roles/storage/tasks/generic/clusterfs-glusterfs.yml
new file mode 100644
index 0000000..1a6b19f
--- /dev/null
+++ b/ansible/node/roles/storage/tasks/generic/clusterfs-glusterfs.yml
@@ -0,0 +1,8 @@
+- name: Include ansible roles for Gluster cluster setup
+ include_role:
+ name: '{{ gluster-ansible-roles }}'
+ with_list:
+ - gluster.infra
+ - gluster.cluster
+ loop_control:
+ loop_var: gluster-ansible-roles
diff --git a/ansible/node/roles/storage/vars/main.yml b/ansible/node/roles/storage/vars/main.yml
new file mode 100644
index 0000000..e215ee4
--- /dev/null
+++ b/ansible/node/roles/storage/vars/main.yml
@@ -0,0 +1,44 @@
+gluster_infra_volume_groups:
+ - { vgname: 'vg_vdb', pvname: '/dev/vdb' }
+ - { vgname: 'vg_vdc', pvname: '/dev/vdc' }
+
+gluster_infra_thinpools:
+ - {vgname: 'vg_vdb', thinpoolname: 'vg_vdb_thinpool', thinpoolsize: '9G', poolmetadatasize: '100M' }
+ - {vgname: 'vg_vdc', thinpoolname: 'vg_vdc_thinpool', thinpoolsize: '9G', poolmetadatasize: '100M' }
+
+gluster_infra_lv_logicalvols:
+ - { vgname: 'vg_vdb', thinpool: 'vg_vdb_thinpool', lvname: 'vg_vdb_thinlv', lvsize: '9G' }
+ - { vgname: 'vg_vdc', thinpool: 'vg_vdc_thinpool', lvname: 'vg_vdc_thinlv', lvsize: '9G' }
+
+gluster_infra_mount_devices:
+ - { path: '/bricks/brick0', vgname: 'vg_vdb', lvname: 'vg_vdb_thinlv' }
+ - { path: '/bricks/brick1', vgname: 'vg_vdc', lvname: 'vg_vdc_thinlv' }
+
+gluster_infra_fw_ports:
+ - 2049/tcp
+ - 54321/tcp
+ - 5900/tcp
+ - 5900-6923/tcp
+ - 5666/tcp
+ - 16514/tcp
+
+gluster_infra_fw_permanent: true
+
+gluster_infra_fw_state: enabled
+
+gluster_infra_fw_zone: public
+
+gluster_infra_fw_services:
+ - glusterfs
+
+gluster_cluster_hosts:
+ - storage0
+ - storage1
+
+gluster_cluster_volume: vol
+
+gluster_cluster_replica_count: 2
+
+gluster_cluster_transport: 'tcp'
+
+gluster_cluster_bricks: '/bricks/brick0/vol,/bricks/brick1/vol'