From e02fde05c68de7278974395fdfca46c0dac58d84 Mon Sep 17 00:00:00 2001 From: jgoutin Date: Wed, 27 Nov 2019 13:55:26 +0100 Subject: [PATCH] Update facts as tasks instead of handler. --- handlers/main.yml | 3 --- tasks/main.yml | 7 ++++++- 2 files changed, 6 insertions(+), 4 deletions(-) delete mode 100644 handlers/main.yml diff --git a/handlers/main.yml b/handlers/main.yml deleted file mode 100644 index 1e248ce..0000000 --- a/handlers/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- -- name: Update facts - setup: diff --git a/tasks/main.yml b/tasks/main.yml index ac95a15..3976f4d 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -139,4 +139,9 @@ when: - reboot_on_kernel_update | bool - (not (ansible_kernel | kernel_match(_kernel)) or reboot_flag.stat.exists) - notify: 'Update facts' + +- name: Update facts + setup: + when: + - reboot_on_kernel_update | bool + - (not (ansible_kernel | kernel_match(_kernel)) or reboot_flag.stat.exists)