fix(role): replaces ansible.builtin.fetch with ansible.posix.synchronize to pull the directory
This commit is contained in:
@@ -1,20 +1,23 @@
|
|||||||
---
|
---
|
||||||
- name: Fetch all certificates from cert-proxy
|
- name: Pull directory from remote host to control node
|
||||||
ansible.builtin.fetch:
|
ansible.posix.synchronize:
|
||||||
|
mode: pull
|
||||||
src: /tmp/letsencrypt
|
src: /tmp/letsencrypt
|
||||||
dest: /tmp
|
dest: /tmp
|
||||||
when: "{{ inventory_hostname == 'cert-proxy' }}"
|
recursive: true
|
||||||
|
delete: true
|
||||||
|
when: "inventory_hostname == 'cert-proxy'"
|
||||||
|
|
||||||
- name: Push loki.vmn.su certificate to the target
|
- name: Push loki.vmn.su certificate to the target
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: /tmp/letsencrypt/live/loki.vmn.su/fullchain.pem
|
src: /tmp/letsencrypt/live/loki.vmn.su/fullchain.pem
|
||||||
dest: /etc/nginx/certs/loki_fullchain.pem
|
dest: /etc/nginx/certs/loki_fullchain.pem
|
||||||
local_follow: true
|
local_follow: true
|
||||||
when: "{{ inventory_hostname == 'monitoring' }}"
|
when: "inventory_hostname == 'monitoring'"
|
||||||
|
|
||||||
- name: Push loki.vmn.su key to the target
|
- name: Push loki.vmn.su key to the target
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: /tmp/letsencrypt/live/loki.vmn.su/privkey.pem
|
src: /tmp/letsencrypt/live/loki.vmn.su/privkey.pem
|
||||||
dest: /etc/nginx/certs/loki_privkey.pem
|
dest: /etc/nginx/certs/loki_privkey.pem
|
||||||
local_follow: true
|
local_follow: true
|
||||||
when: "{{ inventory_hostname == 'monitoring' }}"
|
when: "inventory_hostname == 'monitoring'"
|
||||||
|
|||||||
Reference in New Issue
Block a user