From 5ae7e3cd67a1d54b6d46038dd50471d5d550080d Mon Sep 17 00:00:00 2001 From: bmeehan Date: Mon, 19 Aug 2024 15:35:31 +1000 Subject: [PATCH] ITPLT-3960 fix test --- roles/product_common/tasks/amazon-2023.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/roles/product_common/tasks/amazon-2023.yml b/roles/product_common/tasks/amazon-2023.yml index fc794bc..dc994bd 100644 --- a/roles/product_common/tasks/amazon-2023.yml +++ b/roles/product_common/tasks/amazon-2023.yml @@ -95,11 +95,13 @@ temurin_file_path: "{{ item.path }}" temurin_file_name: "{{ item.path | basename }}" loop: "{{ temurin_rpm_file.files | flatten }}" + when: "{{ temurin_rpm_file.files | length > 0 }}" - name: Install JDK from cache copy of the rpm file - keepcache ansible.builtin.command: cmd: "dnf -y install {{ temurin_file_path }} --setopt=installonly_limit=3 --setopt=keepcache=1" register: dnf_installed + when: "{{ temurin_rpm_file.files | length > 0 }}" when: - jdk_download_completed_lock.state is defined