From 95b73daa36b23565a8566f71f9b202d3459b685f Mon Sep 17 00:00:00 2001 From: Sam Chudnick Date: Sun, 25 Jun 2023 09:52:36 -0400 Subject: Initial Commit --- roles/linux_base/handlers/main.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 roles/linux_base/handlers/main.yml (limited to 'roles/linux_base/handlers') diff --git a/roles/linux_base/handlers/main.yml b/roles/linux_base/handlers/main.yml new file mode 100644 index 0000000..0065ae9 --- /dev/null +++ b/roles/linux_base/handlers/main.yml @@ -0,0 +1,16 @@ +- name: update and upgrade - debian + when: ansible_facts['distribution'] == 'Debian' + become: yes + apt: + name: "*" + state: latest + update_cache: yes + register: apt_upgrade + retries: 100 + until: apt_upgrade is success or ('Failed to lock apt for exclusive operation' not in apt_upgrade.msg and '/var/lib/dpkg/lock' not in apt_upgrade.msg) + +- name: update and upgrade - fedora + when: ansible_facts['distribution'] == 'Fedora' + dnf: + name: "*" + state: latest -- cgit v1.2.3