-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgalaxy.yaml
51 lines (38 loc) · 1.76 KB
/
galaxy.yaml
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
---
- hosts: localhost
vars:
galaxy_install_dir: '/opt/galaxy'
galaxy_listen_host: '127.0.0.1'
tasks:
- name: Install dependencies (CentOS/RHEL)
yum: name={{ item }} state=present
with_items:
- java-openjdk
- httpd
- mod_ssl
when: ansible_distribution == 'CentOS' or ansible_distribution == 'RedHat'
- name: Create galaxy user
user: name=galaxy shell=/bin/bash
- name: Clone galaxy git repository
git: repo=https://github.com/galaxyproject/galaxy/ dest="{{ galaxy_install_dir}}"
- name: "Put in a custome conf file"
template: src=galaxy.ini.j2 dest="{{ galaxy_install_dir }}/config/galaxy.ini" owner=galaxy group=galaxy mode=0644
- name: fix-perms
command: "chown -R galaxy:galaxy {{ galaxy_install_dir }}"
- name: Create Systemd Startup/Stop script (RHEL)
template: src=galaxyd.service.j2 dest=/usr/lib/systemd/system/galaxyd.service owner=root group=root mode=0644
when: ansible_distribution == 'CentOS' or ansible_distribution == 'RedHat'
- name: Create Systemd Startup/Stop script (Ubuntu)
template: src=galaxyd.service.j2 dest=/lib/systemd/system/galaxyd.service owner=root group=root mode=0644
notify: reload-systemd
when: ansible_distribution == 'Debian' or ansible_distribution == 'Ubuntu'
- name: Kick off the service
service: name=galaxyd state=started enabled=yes
- name: Open up Firewall
command: firewall-cmd --permanent --zone=public --add-port=443/tcp
when: ansible_distribution == 'CentOS' or ansible_distribution == 'RedHat'
notify: Reload Firewall
handlers:
- name: Reload Firewall
command: firewall-cmd --reload
when: ansible_distribution == 'CentOS' or ansible_distribution == 'RedHat'