ansible-role-nginx/molecule/common/playbooks/unit_converge.yml

33 lines
779 B
YAML
Raw Normal View History

2018-06-27 01:41:35 +02:00
---
- name: Converge
hosts: all
pre_tasks:
2020-08-19 18:39:17 +02:00
- name: Set module if Alpine
set_fact:
module:
2020-08-19 18:39:17 +02:00
- unit-perl
- unit-php7
- unit-python3
2020-09-15 21:27:06 +02:00
when: ansible_facts['os_family'] == "Alpine"
- name: Set module if Debian
set_fact:
module:
2020-08-19 18:39:17 +02:00
- unit-perl
- unit-php
- unit-ruby
2020-09-15 21:27:06 +02:00
when: ansible_facts['os_family'] == "Debian"
- name: Set module if Red Hat
set_fact:
module:
2020-08-19 18:39:17 +02:00
- unit-php
- unit-go
2020-09-15 21:27:06 +02:00
when: ansible_facts['os_family'] == "RedHat"
2020-08-19 18:39:17 +02:00
tasks:
- name: Install NGINX Unit
include_role:
name: ansible-role-nginx
vars:
nginx_enable: false
nginx_unit_enable: true
nginx_unit_modules: "{{ module }}"