🚀 Manage Ubuntu
parent
424160f9d4
commit
0fd16bdd1e
|
@ -26,9 +26,12 @@ Supported OS:
|
||||||
| Debian Stretch (9) | Yes | Check latest supported version ([1.9.0](https://github.com/HanXHX/ansible-nginx/releases/tag/1.9.0)) |
|
| Debian Stretch (9) | Yes | Check latest supported version ([1.9.0](https://github.com/HanXHX/ansible-nginx/releases/tag/1.9.0)) |
|
||||||
| Debian Buster (10) | Yes | Yes |
|
| Debian Buster (10) | Yes | Yes |
|
||||||
| Debian Bullseye (11) | Yes | Yes |
|
| Debian Bullseye (11) | Yes | Yes |
|
||||||
| Debian Bookworm (12) | Yes | No |
|
| Debian Bookworm (12) | Yes | Not yet :) |
|
||||||
| FreeBSD 11 | NA | No |
|
| FreeBSD 11 | NA | No |
|
||||||
| FreeBSD 12 | NA | No |
|
| FreeBSD 12 | NA | No |
|
||||||
|
| Ubuntu 18.04 | Yes | Yes |
|
||||||
|
| Ubuntu 20.04 | Yes | Yes |
|
||||||
|
| Ubuntu 22.04 | Yes | Yes |
|
||||||
|
|
||||||
Requirements
|
Requirements
|
||||||
------------
|
------------
|
||||||
|
|
|
@ -14,6 +14,11 @@ galaxy_info:
|
||||||
- buster
|
- buster
|
||||||
- bullseye
|
- bullseye
|
||||||
- bookworm
|
- bookworm
|
||||||
|
- name: Ubuntu
|
||||||
|
versions:
|
||||||
|
- bionic
|
||||||
|
- focal
|
||||||
|
- jammy
|
||||||
- name: FreeBSD
|
- name: FreeBSD
|
||||||
versions:
|
versions:
|
||||||
- '11.0'
|
- '11.0'
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
tasks:
|
tasks:
|
||||||
|
|
||||||
- name: INCLUDE_TASKS | Pre tasks related to OS
|
- name: INCLUDE_TASKS | Pre tasks related to OS
|
||||||
ansible.builtin.include_tasks: "../../tests/includes/pre_{{ ansible_distribution }}.yml"
|
ansible.builtin.include_tasks: "../../tests/includes/pre_{{ ansible_os_family }}.yml"
|
||||||
|
|
||||||
- name: INCLUDE_TASKS | Pre_tasks common
|
- name: INCLUDE_TASKS | Pre_tasks common
|
||||||
ansible.builtin.include_tasks: "../../tests/includes/pre_common.yml"
|
ansible.builtin.include_tasks: "../../tests/includes/pre_common.yml"
|
||||||
|
|
|
@ -111,7 +111,7 @@ nginx_ssl_pairs:
|
||||||
|
|
||||||
nginx_custom_http:
|
nginx_custom_http:
|
||||||
- 'add_header X-ansible 1;'
|
- 'add_header X-ansible 1;'
|
||||||
- 'geoip_country {% if ansible_distribution == "Debian" %}/usr/share/GeoIP/GeoIP.dat{% else %}/usr/local/share/GeoIP/GeoIP.dat{% endif %};'
|
- 'geoip_country {% if ansible_os_family == "Debian" %}/usr/share/GeoIP/GeoIP.dat{% else %}/usr/local/share/GeoIP/GeoIP.dat{% endif %};'
|
||||||
- 'map $geoip_country_code $allowed_country {'
|
- 'map $geoip_country_code $allowed_country {'
|
||||||
- ' default yes;'
|
- ' default yes;'
|
||||||
- ' MA no;'
|
- ' MA no;'
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
- name: APT | Install nginx and dependencies
|
- name: APT | Install nginx and dependencies
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
pkg: "{{ nginx_apt_package }}"
|
pkg: "{{ nginx_apt_package }}"
|
||||||
default_release: "{{ ansible_distribution_release + '-backports' if nginx_backports else ansible_distribution_release }}"
|
default_release: "{{ ansible_distribution_release + '-backports' if (nginx_backports and ansible_distribution == 'Debian') else ansible_distribution_release }}"
|
||||||
|
|
||||||
- name: APT | Install nginx modules
|
- name: APT | Install nginx modules
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
---
|
---
|
||||||
|
|
||||||
- name: INCLUDE_TASKS | Install
|
- name: INCLUDE_TASKS | Install
|
||||||
ansible.builtin.include_tasks: "{{ ansible_distribution }}.yml"
|
ansible.builtin.include_tasks: "{{ ansible_os_family }}.yml"
|
||||||
|
|
||||||
- name: IMPORT_TASKS | acme
|
- name: IMPORT_TASKS | acme
|
||||||
ansible.builtin.import_tasks: "acme.yml"
|
ansible.builtin.import_tasks: "acme.yml"
|
||||||
|
|
|
@ -104,7 +104,7 @@ nginx_ssl_pairs:
|
||||||
|
|
||||||
nginx_custom_http:
|
nginx_custom_http:
|
||||||
- 'add_header X-ansible 1;'
|
- 'add_header X-ansible 1;'
|
||||||
- 'geoip_country {% if ansible_distribution == "Debian" %}/usr/share/GeoIP/GeoIP.dat{% else %}/usr/local/share/GeoIP/GeoIP.dat{% endif %};'
|
- 'geoip_country {% if ansible_os_family == "Debian" %}/usr/share/GeoIP/GeoIP.dat{% else %}/usr/local/share/GeoIP/GeoIP.dat{% endif %};'
|
||||||
- 'map $geoip_country_code $allowed_country {'
|
- 'map $geoip_country_code $allowed_country {'
|
||||||
- ' default yes;'
|
- ' default yes;'
|
||||||
- ' MA no;'
|
- ' MA no;'
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
hosts: all
|
hosts: all
|
||||||
pre_tasks:
|
pre_tasks:
|
||||||
- name: INCLUDE_TASKS | Pre_tasks related to OS version
|
- name: INCLUDE_TASKS | Pre_tasks related to OS version
|
||||||
ansible.builtin.include_tasks: "includes/pre_{{ ansible_distribution }}.yml"
|
ansible.builtin.include_tasks: "includes/pre_{{ ansible_os_family }}.yml"
|
||||||
|
|
||||||
- name: IMPORT_TASKS | Pre_tasks common
|
- name: IMPORT_TASKS | Pre_tasks common
|
||||||
ansible.builtin.import_tasks: "includes/pre_common.yml"
|
ansible.builtin.import_tasks: "includes/pre_common.yml"
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
post_tasks:
|
post_tasks:
|
||||||
- name: INCLUDE_TASKS | Post_tasks related to OS version
|
- name: INCLUDE_TASKS | Post_tasks related to OS version
|
||||||
ansible.builtin.include_tasks: "includes/post_{{ ansible_distribution }}.yml"
|
ansible.builtin.include_tasks: "includes/post_{{ ansible_os_family }}.yml"
|
||||||
|
|
||||||
- name: IMPORT_TASKS | Post_tasks common
|
- name: IMPORT_TASKS | Post_tasks common
|
||||||
ansible.builtin.import_tasks: "includes/post_common.yml"
|
ansible.builtin.import_tasks: "includes/post_common.yml"
|
||||||
|
|
Loading…
Reference in New Issue