17 lines
551 B
YAML
17 lines
551 B
YAML
---
|
|
|
|
- name: FAIL | If Dynamic module is not available
|
|
fail: msg="{{ item }} dynamic module is not available"
|
|
with_items: "{{ nginx_dyn_modules }}"
|
|
when: "'{{ item }}=dynamic' not in nginx_modules"
|
|
|
|
- name: APT | Install nginx modules
|
|
apt: >
|
|
pkg="libnginx-mod-{{ item | replace('_', '-') }}"
|
|
state=present
|
|
default_release={{ ansible_distribution_release + '-backports' if nginx_backports else ansible_distribution_release }}
|
|
with_items: "{{ nginx_dyn_modules }}"
|
|
when: ansible_distribution == 'Debian'
|
|
|
|
# TODO: manage freebsd
|