From 5f880d82c5c44ce3e76460cb0d64b46b414660d6 Mon Sep 17 00:00:00 2001 From: diodonfrost Date: Fri, 28 Dec 2018 13:00:01 +0100 Subject: [PATCH] update debian and gentoo cache before installing ntp daemon --- tasks/packages/setup-Linux.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tasks/packages/setup-Linux.yml b/tasks/packages/setup-Linux.yml index 9f3ac2c..922fade 100644 --- a/tasks/packages/setup-Linux.yml +++ b/tasks/packages/setup-Linux.yml @@ -1,6 +1,17 @@ --- # Tasks file for install ntp daemon on Linux system +- name: Update apt cache on Debian Family os + apt: + update_cache: yes + changed_when: false + when: ansible_os_family == "Debian" + +- name: Update emerge cache on Gentoo + shell: emerge-webrsync + changed_when: false + when: ansible_os_family == "Gentoo" + - name: Install ntp daemon on Linux package: name: "{{ ntp_package }}"