Certs generation command update

This commit is contained in:
Gonzalo Acuña 2022-03-23 10:41:14 -03:00
parent 67b3b320f9
commit eb133c4720
No known key found for this signature in database
GPG Key ID: 646BA79A313A2270
4 changed files with 7 additions and 7 deletions

View File

@ -10,7 +10,7 @@
- name: Copy the certificates from local to the Manager instance
copy:
src: "{{ local_certs_path }}/certs/{{ item }}"
src: "{{ local_certs_path }}/wazuh-certificates/{{ item }}"
dest: "{{ filebeat_ssl_dir }}"
owner: root
group: root

View File

@ -2,7 +2,7 @@
- name: Copy the certificates from local to the Wazuh dashboard instance
copy:
src: "{{ local_certs_path }}/certs/{{ item }}"
src: "{{ local_certs_path }}/wazuh-certificates/{{ item }}"
dest: /etc/wazuh-dashboard/certs/
mode: 0644
with_items:

View File

@ -19,13 +19,13 @@
- name: Local action | Check that the generation tool exists
stat:
path: "{{ local_certs_path }}/wazuh-cert-tool.sh"
path: "{{ local_certs_path }}/wazuh-certs-tool.sh"
register: tool_package
- name: Local action | Download certificates generation tool
get_url:
url: "{{ certs_gen_tool_url }}"
dest: "{{ local_certs_path }}/wazuh-cert-tool.sh"
dest: "{{ local_certs_path }}/wazuh-certs-tool.sh"
when: not tool_package.stat.exists
- name: Local action | Prepare the certificates generation template file
@ -37,12 +37,12 @@
- name: Local action | Generate the node & admin certificates in local
command: >-
bash {{ local_certs_path }}/wazuh-cert-tool.sh
bash {{ local_certs_path }}/wazuh-certs-tool.sh -A
become: yes
- name: Get Certificate files
find:
paths: "{{ local_certs_path }}/certs"
paths: "{{ local_certs_path }}/wazuh-certificates"
patterns: "*"
register: certificate_files

View File

@ -22,7 +22,7 @@
- name: Copy the node & admin certificates to Wazuh indexer cluster
copy:
src: "{{ local_certs_path }}/certs/{{ item }}"
src: "{{ local_certs_path }}/wazuh-certificates/{{ item }}"
dest: "{{ indexer_conf_path }}/certs/"
mode: 0644
become: yes