You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
876 B
30 lines
876 B
---
|
|
- name: Get DMC Name
|
|
set_fact:
|
|
dmc_name: "{{ hostvars[groups.splunk_monitoring_console[0]].inventory_hostname_short }}"
|
|
when: not splunk_single_instance
|
|
|
|
- name: "Ensure that {{ dest_path }} exists"
|
|
file:
|
|
path: "{{ splunk_home }}/etc/{{ dest_path | dirname }}"
|
|
state: directory
|
|
recurse: yes
|
|
group: "{{ splunk_group }}"
|
|
owner: "{{ splunk_user }}"
|
|
ignore_errors: true
|
|
vars:
|
|
dest_path: "auth/distServerKeys/{{ dmc_name }}/"
|
|
become: yes
|
|
become_user: "{{ splunk_user }}"
|
|
when: not splunk_single_instance
|
|
|
|
- name: Copy trusted.pem to server
|
|
copy:
|
|
src: "/tmp/trusted.pem"
|
|
dest: "{{ splunk_home }}/etc/auth/distServerKeys/{{ dmc_name }}/trusted.pem"
|
|
group: "{{ splunk_group }}"
|
|
owner: "{{ splunk_user }}"
|
|
become: yes
|
|
become_user: "{{ splunk_user }}"
|
|
when: not splunk_single_instance
|