ansible-role-nginx/tasks/unit/install-unit.yml

27 lines
725 B
YAML
Raw Normal View History

2018-04-07 01:32:48 +02:00
---
- import_tasks: setup-debian.yml
when: ansible_os_family == "Debian"
- import_tasks: setup-redhat.yml
when: ansible_os_family == "RedHat"
2018-07-18 23:59:14 +02:00
- import_tasks: setup-freebsd.yml
when: ansible_os_family == "FreeBSD"
- name: "(Install: Debian/Ubuntu/CentOS/RedHat) Install NGINX Unit"
2018-04-07 01:32:48 +02:00
package:
name: unit
state: present
2018-07-18 23:59:14 +02:00
when: ansible_os_family != "FreeBSD"
notify: "(Handler: Debian/Ubuntu/CentOS/RedHat) Start NGINX Unit"
- name: "(Install: FreeBSD) Install NGINX Unit"
portinstall:
name: unit
state: present
when: ansible_os_family == "FreeBSD"
notify: "(Handler: FreeBSD) Start NGINX Unit"
2018-04-07 01:32:48 +02:00
- import_tasks: install-modules.yml
when: nginx_unit_modules is defined and nginx_unit_modules