diff --git a/installcurl.yml b/installPackages.yml similarity index 100% rename from installcurl.yml rename to installPackages.yml diff --git a/installVIM.yml b/installVIM.yml deleted file mode 100644 index 0b59641..0000000 --- a/installVIM.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- -- hosts: all - become: yes - tasks: - - name: Install Vim on Ubuntu servers - package: - name: vim - state: present - when: ansible_facts['os_family'] == 'Debian' - - - name: Install Vim on Fedora servers - dnf: - name: vim - state: present - when: ansible_facts['distribution'] == 'Fedora' diff --git a/update_machines.yml b/update_machines.yml index ce64c06..b582a39 100644 --- a/update_machines.yml +++ b/update_machines.yml @@ -7,11 +7,20 @@ apt: upgrade: dist update_cache: yes - when: ansible_facts['distribution'] == 'Ubuntu' - - name: Install Neofetch - become: true - ansible.builtin.dnf: - name: neofetch - state: present - when: ansible_facts['distribution'] == 'Fedora' + - name: Make sure Zypper is installed + ansible.builtin.apt: + name: "zypper" + state: installed + + - name: See if pct needs a reboot + ansible.builtin.shell: "needs-restarting -r > /dev/null; echo $?" + register: needsRestarting + - name: debug + ansible.builtin.apt: + msg: "{{ needsRestarting }}" + + - name: Reboot the Container + ansible.builtin.reboot: + reboot_timeout: 600 + when: needsRestarting.stdout == "1"