ansible-role-nginx/tasks/plus/setup-debian.yml
Alessandro Fael Garcia bf2916fc55
Update Ansible to 2.9.12 and explicitly set mode on relevant tasks (#309)
*   Explicitly define `mode` in relevant tasks.
*   Explicitly define the `nginx` `apt_repository` filename in Debian based distros.
*   Building OpenSSL from source should now work properly in CentOS 8.
2020-08-28 10:30:23 +02:00

21 lines
863 B
YAML

---
- name: "(Setup: Debian/Ubuntu) Setup NGINX Plus License"
blockinfile:
path: /etc/apt/apt.conf.d/90nginx
create: yes
block: |
Acquire::https::plus-pkgs.nginx.com::Verify-Peer "true";
Acquire::https::plus-pkgs.nginx.com::Verify-Host "true";
Acquire::https::plus-pkgs.nginx.com::SslCert "/etc/ssl/nginx/nginx-repo.crt";
Acquire::https::plus-pkgs.nginx.com::SslKey "/etc/ssl/nginx/nginx-repo.key";
state: "{{ nginx_license_status | default ('present') }}"
mode: 0444
- name: "(Setup: Debian/Ubuntu) Setup NGINX Plus Repository"
apt_repository:
filename: nginx-plus
repo: deb [arch=amd64] https://plus-pkgs.nginx.com/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} nginx-plus
update_cache: yes
state: "{{ nginx_license_status | default ('present') }}"
mode: 0644