Switch to using get_url module over curl

Switch to using the get_url Ansible module over curl.
This change is for obtaining the filebeat SSL certificate
for the client to connect and send logs over TLS to the
logstash instance.

Patchset #2: make get_url commands be on multiple lines.

Change-Id: I4dfe7e922b576624f23f204c8f696ea8f0a75e14
This commit is contained in:
Will Foster 2016-08-31 15:31:27 +01:00
parent ffbd1a92ec
commit 1fd975aee7

View File

@ -43,7 +43,9 @@
when: (logging_backend != 'fluentd')
- name: Install ELK server SSL client certificate
shell: curl http://"{{ elk_server }}":{{ elk_server_ssl_cert_port }}/filebeat-forwarder.crt > /etc/pki/tls/certs/filebeat-forwarder.crt
get_url:
url=http://{{ elk_server }}:{{ elk_server_ssl_cert_port }}/filebeat-forwarder.crt
dest=/etc/pki/tls/certs/filebeat-forwarder.crt
become: true
when: ((elk_client_ssl_cert_exists != 0) and (logging_backend != 'fluentd'))