extend existing certificate list instead of overwriting it. Ansible realy needs a deep merge...
This commit is contained in:
parent
d2ddb8a666
commit
1ddb7fa78d
4 changed files with 10 additions and 5 deletions
|
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
nginx:
|
nginx:
|
||||||
add_headers: []
|
add_headers: []
|
||||||
real_ip_from:
|
real_ip_from:
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,3 @@
|
||||||
---
|
---
|
||||||
dependencies:
|
dependencies:
|
||||||
- { role: monitoring, when: nginx.monitoring }
|
- { role: monitoring, when: nginx.monitoring }
|
||||||
- certificates
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,14 @@
|
||||||
---
|
---
|
||||||
|
- set_fact:
|
||||||
|
nginx_certs: "{{ nginx.vhosts|nginx_vhosts_to_certificates }}"
|
||||||
|
inventory_certs: "{{ certificates.certs|d({}) }}"
|
||||||
|
|
||||||
|
- include_role:
|
||||||
|
name: certificates
|
||||||
|
vars:
|
||||||
|
certificates:
|
||||||
|
certs: "{{ {}|combine(nginx_certs, inventory_certs, recursive=True) }}"
|
||||||
|
|
||||||
- name: install nginx
|
- name: install nginx
|
||||||
apt: pkg=nginx
|
apt: pkg=nginx
|
||||||
notify:
|
notify:
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,3 @@ monitoring:
|
||||||
checks:
|
checks:
|
||||||
local:
|
local:
|
||||||
nginx_status: {}
|
nginx_status: {}
|
||||||
|
|
||||||
certificates:
|
|
||||||
certs: "{{ nginx.vhosts|nginx_vhosts_to_certificates }}"
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue