|
|
|
@ -4,7 +4,17 @@ |
|
|
|
|
set_fact: nas_shares_conf={{ nas_shares_conf | default([]) + [nas_default_share | combine(item,recursive=True)] }} |
|
|
|
|
with_items: "{{ nas_shares }}" |
|
|
|
|
tags: nas |
|
|
|
|
- set_fact: nas_shares={{ nas_shares_conf }} |
|
|
|
|
- set_fact: nas_shares={{ nas_shares_conf | default([]) }} |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Install needed packages |
|
|
|
|
yum: |
|
|
|
|
name: |
|
|
|
|
- rssh |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Allow every user to use rssh |
|
|
|
|
file: path=/bin/rssh mode=755 |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Create directories |
|
|
|
@ -27,7 +37,7 @@ |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Deploy NFS exports |
|
|
|
|
template: src=exports.j2 dest=/etc/exports |
|
|
|
|
template: src=exports.j2 dest=/etc/exports.d/shares.exports |
|
|
|
|
notify: reload nfs |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
@ -40,6 +50,12 @@ |
|
|
|
|
with_items: "{{ nas_shares }}" |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Deploy httpd conf |
|
|
|
|
template: src=httpd.conf.j2 dest=/etc/httpd/ansible_conf.d/50-shares.conf mode=640 |
|
|
|
|
notify: |
|
|
|
|
- reload httpd |
|
|
|
|
tags: nas |
|
|
|
|
|
|
|
|
|
- name: Deploy setfacl script |
|
|
|
|
template: src=setfacl.sh.j2 dest={{ nas_root_dir }}/meta/{{ item.name }}/setfacl.sh mode=755 |
|
|
|
|
with_items: "{{ nas_shares }}" |
|
|
|
|