From 89719f798fec541e7aa5683d8fc5c972e2978938 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Sachse?= <joerg.sachse@slub-dresden.de> Date: Fri, 26 Jul 2024 09:06:05 +0200 Subject: [PATCH] fix: improve task waiting for ClamAV signature databases to be downloaded by being more precise about DB names and extending timeout for slow connections --- tasks/install_clamav.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/tasks/install_clamav.yml b/tasks/install_clamav.yml index bdb43ff..922903e 100644 --- a/tasks/install_clamav.yml +++ b/tasks/install_clamav.yml @@ -164,7 +164,16 @@ - name: wait for signature file to appear ansible.builtin.wait_for: - path: "/var/lib/clamav/daily.cld" + path: "/var/lib/clamav/{{ item }}" + timeout: 600 # Maximum number of seconds to wait for + loop: + - "bytecode.cvd" # compiled bytecode signatures evaluated by the + # bytecode interpreter engine + # - "daily.cld" # signatures for the latest threats (updated daily) + # We don't wait for these, because they might not exist + # on a fresh installation. + - "main.cvd" # signatures previously in daily.cvd that have shown to + # have a low false-positive risk. when: ansible_os_family == "RedHat" - name: find out if unnecessary systemd service exists -- GitLab