Files
hatarashi-pasokom/hatarashi-pasokom.yaml
shmick 84435dfd35
Some checks failed
Ansible Deploy / deploy (push) Failing after 55s
This isn't actually needed?
2023-11-24 08:48:10 +02:00

25 lines
584 B
YAML

---
- hosts: takahe
gather_facts: yes
become: yes
vars:
ansible_ssh_common_args: '-o StrictHostKeyChecking=no'
ansible_sudo_pass: "${{ secrets.SUDO_PASS }}"
tasks:
- name: Update all installed packages using APT module
apt:
name: '*'
state: latest
update_cache: yes
only_upgrade: yes
register: apt_update_status
- name: Remove packages not needed anymore
apt:
autoremove: yes
- name: Reboot when packages were updated
reboot:
post_reboot_delay: 60
when: apt_update_status.changed