ansible/roles/taskotron/resultsdb-frontend/tasks/main.yml
2019-05-23 09:06:09 +02:00

30 lines
1.1 KiB
YAML

---
- name: start httpd (provided in the apache role)
service: name=httpd state=started
- name: ensure packages required for resultsdb_frontend are installed (yum - required for testdays)
package: name={{ item }} state=present
with_items:
- resultsdb_frontend
- mod_wsgi
when: ansible_distribution_major_version|int < 22
- name: ensure packages required for resultsdb_frontend are installed (dnf)
dnf: name={{ item }} state=present
with_items:
- resultsdb_frontend
- python3-mod_wsgi
when: ansible_distribution_major_version|int > 21 and ansible_cmdline.ostree is not defined
- name: ensure selinux lets httpd talk to the network
seboolean: name=httpd_can_network_connect persistent=yes state=yes
- name: generate resultsdb_frontend config
template: src=settings.py.j2 dest=/etc/resultsdb_frontend/settings.py owner=root group=root mode=0644
notify:
- reload httpd
- name: generate resultsdb_frontend apache config
template: src=resultsdb_frontend.conf.j2 dest=/etc/httpd/conf.d/resultsdb_frontend.conf owner=root group=root mode=0644
notify:
- reload httpd