feat: use builtin virtualisation detection

This commit is contained in:
Simon Cornet 2026-04-10 14:23:17 +02:00
commit 02d15fb57a
6 changed files with 15 additions and 14 deletions

View file

@ -18,4 +18,4 @@
ansible.builtin.command: "fstrim /"
changed_when: false
failed_when: false
when: 'type == "vm"'
when: "ansible_virtualization_type == 'kvm'"

View file

@ -35,7 +35,7 @@
cmd: "fstrim /"
changed_when: false
failed_when: false
when: 'type == "vm"'
when: "ansible_virtualization_type == 'kvm'"
# check for reboots
- name: "check if reboot required"