Add os-update playbook
This commit is contained in:
@@ -17,6 +17,7 @@ on:
|
|||||||
- gitea.yml
|
- gitea.yml
|
||||||
- vaultwarden.yml
|
- vaultwarden.yml
|
||||||
- runner.yml
|
- runner.yml
|
||||||
|
- os-update.yml
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
ansible:
|
ansible:
|
||||||
|
|||||||
15
ansible/os-update.yml
Normal file
15
ansible/os-update.yml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
- name: OS updates
|
||||||
|
hosts: infra
|
||||||
|
become: true
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: Update apt cache and upgrade packages
|
||||||
|
apt:
|
||||||
|
update_cache: true
|
||||||
|
upgrade: safe
|
||||||
|
|
||||||
|
- name: Remove unused packages
|
||||||
|
apt:
|
||||||
|
autoremove: true
|
||||||
|
purge: true
|
||||||
Reference in New Issue
Block a user