From ea5c3d08da8842a0b5c991f9808a303d8da06f77 Mon Sep 17 00:00:00 2001 From: Tristan Cacqueray Date: Tue, 5 Dec 2017 09:09:30 +0000 Subject: [PATCH] bindep: skip package install when not needed When bindep test doesn't output package, there is no need to run the package task. Change-Id: I6f13e060a6d9657d3dec4f43a0b9c2dbff2d362d --- roles/bindep/tasks/packages.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/roles/bindep/tasks/packages.yaml b/roles/bindep/tasks/packages.yaml index 5967a1f79..8963a40a7 100644 --- a/roles/bindep/tasks/packages.yaml +++ b/roles/bindep/tasks/packages.yaml @@ -8,6 +8,7 @@ name: "{{ bindep_output.stdout_lines }}" state: present become: yes + when: bindep_output.stdout_lines - name: Check that packages are installed command: "{{ bindep_run }}"