Implemented tasks to import custom key and cert from Ansible master

This commit is contained in:
Jose M 2019-08-05 15:01:21 +02:00
parent 8234bb11d2
commit 01d4cfc128

View File

@ -39,6 +39,22 @@
when: when:
- node_certs_generator - node_certs_generator
- name: Importing custom CA key
copy:
src: "{{ master_certs_destination }}/ca/{{ ca_key_name }}"
dest: "{{ node_certs_source }}/{{ ca_key_name }}"
when:
- not generate_CA
tags: xpack-security
- name: Importing custom CA cert
copy:
src: "{{ master_certs_destination }}/ca/{{ ca_cert_name }}"
dest: "{{ node_certs_source }}/{{ ca_cert_name }}"
when:
- not generate_CA
tags: xpack-security
- name: Generating certificates for Elasticsearch security (generating CA) - name: Generating certificates for Elasticsearch security (generating CA)
shell: >- shell: >-
/usr/share/elasticsearch/bin/elasticsearch-certutil cert ca --pem --in /usr/share/elasticsearch/bin/elasticsearch-certutil cert ca --pem --in