Copy .key and .crt in generator node (locally)
This commit is contained in:
parent
a1e6dec7b4
commit
2525dbd2af
@ -109,14 +109,14 @@
|
|||||||
- name: Unzip generated certs.zip
|
- name: Unzip generated certs.zip
|
||||||
unarchive:
|
unarchive:
|
||||||
src: "{{node_certs_source}}/certs.zip"
|
src: "{{node_certs_source}}/certs.zip"
|
||||||
dest: "{{node_certs_source}}"
|
dest: "{{node_certs_source}}/"
|
||||||
remote_src: yes
|
remote_src: yes
|
||||||
when:
|
when:
|
||||||
- node_certs_generator
|
- node_certs_generator
|
||||||
- elasticsearch_xpack_security
|
- elasticsearch_xpack_security
|
||||||
tags: xpack-security
|
tags: xpack-security
|
||||||
|
|
||||||
- name: Copy local certificate for generator node
|
- name: Copy .key & .crt files in generator node
|
||||||
synchronize:
|
synchronize:
|
||||||
src: "{{node_certs_source}}/{{elasticsearch_node_name}}/"
|
src: "{{node_certs_source}}/{{elasticsearch_node_name}}/"
|
||||||
dest: "{{node_certs_destination}}/"
|
dest: "{{node_certs_destination}}/"
|
||||||
@ -126,7 +126,17 @@
|
|||||||
- elasticsearch_xpack_security
|
- elasticsearch_xpack_security
|
||||||
tags: xpack-security
|
tags: xpack-security
|
||||||
|
|
||||||
- name: Importing certificate generated previously
|
- name: Copy ca .crt file in generator node
|
||||||
|
synchronize:
|
||||||
|
src: "{{node_certs_source}}/ca/"
|
||||||
|
dest: "{{node_certs_destination}}/"
|
||||||
|
delegate_to: "{{ node_certs_generator_ip }}"
|
||||||
|
when:
|
||||||
|
- node_certs_generator
|
||||||
|
- elasticsearch_xpack_security
|
||||||
|
tags: xpack-security
|
||||||
|
|
||||||
|
- name: Importing node .key & .crt files
|
||||||
shell: "{{rsync_path}} {{rsync_extra_parameters}} {{rsync_user}}@{{node_certs_generator_ip}}:{{node_certs_source}}/{{elasticsearch_node_name}}/ {{node_certs_destination}}/"
|
shell: "{{rsync_path}} {{rsync_extra_parameters}} {{rsync_user}}@{{node_certs_generator_ip}}:{{node_certs_source}}/{{elasticsearch_node_name}}/ {{node_certs_destination}}/"
|
||||||
when:
|
when:
|
||||||
- not node_certs_generator
|
- not node_certs_generator
|
||||||
@ -176,9 +186,9 @@
|
|||||||
- wazuh_alerts_template_exits.status != 200
|
- wazuh_alerts_template_exits.status != 200
|
||||||
tags: init
|
tags: init
|
||||||
|
|
||||||
# - import_tasks: "RMRedHat.yml"
|
- import_tasks: "RMRedHat.yml"
|
||||||
# when: ansible_os_family == "RedHat"
|
when: ansible_os_family == "RedHat"
|
||||||
|
|
||||||
|
|
||||||
# - import_tasks: "RMDebian.yml"
|
- import_tasks: "RMDebian.yml"
|
||||||
# when: ansible_os_family == "Debian"
|
when: ansible_os_family == "Debian"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user