From 3d39f3e231198e829e786e7d4bcbdc79ebce8fd6 Mon Sep 17 00:00:00 2001 From: Aaron Guise Date: Tue, 9 Aug 2022 07:41:10 +1200 Subject: [PATCH] Add samba dl tasks --- tasks/RedHat.yml | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/tasks/RedHat.yml b/tasks/RedHat.yml index a4b286d..33e1b1f 100644 --- a/tasks/RedHat.yml +++ b/tasks/RedHat.yml @@ -42,6 +42,15 @@ manager: "auto" when: cmk_force_install +# Download agent by samba share +- include_tasks: downloads/samba/main.yml + when: cmk_download_mode == 'samba' + +- name: Copy installer to node + copy: + src: /tmp/dls/{{ cmk_installer }} + dest: /tmp/check-mk-agent.rpm + - name: Install check-mk-agent block: @@ -64,14 +73,15 @@ validate_certs: false when: not cmkrpm.stat.exists and not cmk_dl_needs_auth|bool - - name: Ensure check_mk_agent installed - command: /usr/bin/yum install --nogpgcheck -y /tmp/check-mk-agent.rpm - args: - warn: no + - name: Ensure check_mk_agent installed + package: + name: /tmp/check-mk-agent.rpm + state: latest + disable_gpg_check: true # Not gpg signed so bypass the check notify: - restart xinetd - cmk fresh install - - ensure firewall open + - ensure firewall open (rhel) when: "'check-mk-agent' not in ansible_facts.packages or cmk_force_install" tags: - check_mk_agent