-
Notifications
You must be signed in to change notification settings - Fork 17
/
pawsey-user-nfs_playbook.yml
52 lines (51 loc) · 1.51 KB
/
pawsey-user-nfs_playbook.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
- hosts: pawsey-user-nfs
become: true
vars_files:
- group_vars/all.yml
- group_vars/pawsey.yml
- group_vars/VAULT
- group_vars/nfs_servers.yml
- host_vars/pawsey-user-nfs.usegalaxy.org.au.yml
- secret_group_vars/stats_server_vault
pre_tasks:
- name: Create galaxy_user_data_2_dir directory
file:
path: "{{ galaxy_user_data_2_dir }}"
state: directory
- name: Create galaxy_user_data_3_dir directory
file:
path: "{{ galaxy_user_data_3_dir }}"
state: directory
- name: Create galaxy_user_data_4_dir directory
file:
path: "{{ galaxy_user_data_4_dir }}"
state: directory
- name: Attach volume to instance
include_role:
name: attached-volumes
- name: Create galaxy_user_data_dir directory
file:
path: "{{ galaxy_user_data_dir }}"
state: directory
roles:
- common
- insspb.hostname
- geerlingguy.pip
- geerlingguy.nfs
- dj-wasabi.telegraf
post_tasks:
- name: Chown shared dirs to Galaxy user
file:
path: "{{ item }}"
owner: galaxy
group: galaxy
# recurse: yes
with_items:
- "{{ galaxy_user_data_dir }}"
- "{{ galaxy_user_data_2_dir }}"
- "{{ galaxy_user_data_3_dir }}"
- "{{ galaxy_user_data_4_dir }}"
- name: Reload exportfs
command: exportfs -ra
become: yes
become_user: root