Skip to content

Commit 736c86c

Browse files
committed
sit.gpfs: Prepare and create shares based on methods
Signed-off-by: Anoop C S <[email protected]>
1 parent 4c7d7c7 commit 736c86c

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

playbooks/ansible/roles/sit.gpfs/tasks/main.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,6 @@
124124
- name: Configure shares
125125
command: >-
126126
/usr/lpp/mmfs/bin/mmsmb export add
127-
{{ item.name }}-{{ config.be.name }}-{{ config.be.variant }}
128-
/gpfs/sit_fs/{{ item.name }}
129-
loop: "{{ samba_shares }}"
127+
{{ item[0].name }}-{{ config.be.name }}-{{ config.be.variant }}-{{ item[1] }}
128+
/gpfs/sit_fs/{{ item[0].name }}
129+
loop: "{{ samba_shares | product(config.be.methods) | list }}"
Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1-
[{{ name }}-{{ config.be.name }}-{{ config.be.variant }}]
2-
comment = Volume '{{ name }}' from {{ config.be.name }}({{ config.be.variant }})
3-
vfs objects = acl_xattr {%- if config.be.variant == 'vfs' %} gpfs{% endif +%}
1+
{%- for method in config.be.methods +%}
2+
[{{ volume.name }}-{{ config.be.name }}-{{ config.be.variant }}-{{ method }}]
3+
comment = Volume '{{ volume.name }}' from {{ config.be.name }}({{ config.be.variant }} {{ method }})
4+
vfs objects = acl_xattr {%- if method != 'kclient' %} gpfs{% endif +%}
45
path = {{ path }}
56
read only = no
6-
{%- for option, value in volume.samba.options.items() | default([]) +%}
7+
{%- for option, value in volume.samba.options.items() | default([]) +%}
78
{{ option }} = {{ value }}
9+
{%- endfor +%}
810
{%- endfor +%}

0 commit comments

Comments
 (0)