diff --git a/roles/splunk/tasks/configure_dmc.yml b/roles/splunk/tasks/configure_dmc.yml index 2132f794..1206d16d 100644 --- a/roles/splunk/tasks/configure_dmc.yml +++ b/roles/splunk/tasks/configure_dmc.yml @@ -1,6 +1,6 @@ --- - name: Check splunk - include_task: check_splunk.yml + include_tasks: check_splunk.yml - name: Configure DMC as a IDXC member include_tasks: configure_idxc_sh.yml @@ -13,6 +13,18 @@ become: true become_user: "{{ splunk_nix_user }}" no_log: true + changed_when: peer_add.rc == 0 + failed_when: peer_add.rc != 0 and peer_add.rc != 24 + +- name: Create local dir if it doesn't exist + ansible.builtin.file: + path: "{{ splunk_home }}/etc/apps/splunk_monitoring_console/local" + state: directory + owner: "{{ splunk_nix_user }}" + group: "{{ splunk_nix_group }}" + mode: 0744 + become: true + become_user: "{{ splunk_nix_user }}" - name: Configure monitoring console in auto mode community.general.ini_file: