-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathdev_playbook.yml
More file actions
120 lines (120 loc) · 3.47 KB
/
Copy pathdev_playbook.yml
File metadata and controls
120 lines (120 loc) · 3.47 KB
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
- hosts: dev_galaxy_server
become: true
vars_files:
- group_vars/all.yml
- group_vars/dev.yml # machine_users overridden in this file
- group_vars/VAULT
- group_vars/galaxyservers.yml
- group_vars/dev_slurm.yml
- host_vars/dev.gvl.org.au.yml
- secret_group_vars/ssh_keys
- secret_group_vars/stats_server_vault
- secret_group_vars/dev_secrets
- secret_group_vars/sentry_vault
pre_tasks:
- name: Attach volume to instance
include_role:
name: attached-volumes
- name: Run common role first to create galaxy user
include_role:
name: common
- name: create dir for gravity configuration
file:
state: directory
path: /opt/galaxy
owner: root
group: galaxy
mode: 0775
- name: create dir for galaxy's singularity cache
file:
state: directory
path: "{{ item }}"
owner: galaxy
group: galaxy
mode: 0700
with_items:
- "{{ galaxy_user_singularity_cachedir }}"
- "{{ galaxy_user_singularity_tmpdir }}"
roles:
- geerlingguy.nfs
- galaxyproject.repos
- role: mounts
tags: mounts
# - install-tpv # todo: this needs a when clause
- geerlingguy.pip
- role: galaxyproject.galaxy
tags: galaxy
- role: galaxyproject.miniconda
become: true
become_user: galaxy
tags: miniconda
# - role: galaxyproject.galaxy_extensions
# tags: extensions
- role: usegalaxy_eu.galaxy_subdomains
tags: galaxy_subdomains
- name: nginx-upload-module
tags: nginx
- name: galaxyproject.nginx
tags: nginx
- galaxyproject.tusd
- geerlingguy.nfs
- galaxyproject.slurm
- galaxyproject.cvmfs
- role: galaxyproject.gxadmin
tags: gxadmin
- remote-pulsar-cron
- galaxy-pg-cleanup
- galaxyproject.tiaas2
- geerlingguy.docker
- usegalaxy_eu.apptainer
- dj-wasabi.telegraf
- postfix-mail-relay
- role: acl-on-startup
tags: setfacl
- role: usegalaxy_eu.walle
tags: walle
- role: vector
tags: vector
- role: usegalaxy-au.history_mailer
tags: history_mailer
post_tasks:
- name: Make local_tool directory group-writable by machine users
file:
path: /mnt/galaxy/local_tools
owner: root
group: devs
mode: 0775
state: directory
tags: galaxy
- name: Install slurm-drmaa
package:
name: slurm-drmaa1
- name: Reload exportfs
command: exportfs -ra
become: yes
become_user: root
# Nginx logrotate: keep nginx logs forever on /mnt disk
- name: Make sure extra nginx log dirs exist
file:
state: directory
path: "{{ item }}"
with_items:
- "{{ nginx_log_olddir_root }}"
- "{{ nginx_long_term_log_dir }}"
tags: nginx
- name: Add lines to main block in nginx logrotate conf
lineinfile:
path: /etc/logrotate.d/nginx
line: "{{ item }}"
insertafter: ".*{"
with_items:
- "\tdateext"
- "\tolddir {{ nginx_log_olddir_root }}"
tags: nginx
- name: Add lines to postrotate task in nginx logrotate conf
lineinfile:
path: /etc/logrotate.d/nginx
regexp: '^\s*cp\s+{{ nginx_log_olddir_root | regex_escape }}/\*\s+{{ nginx_long_term_log_dir | regex_escape }}/$'
line: "\t\tcp {{ nginx_log_olddir_root }}/*.gz {{ nginx_long_term_log_dir }}/"
insertafter: "\tpostrotate"
tags: nginx