- domain names need to match ssh host ids
- dynamic inventory ansible module for
community.libvirt.libvirt
requires qemu-ga running in guest - why not just create a temporary ad-hoc inventory of currently running vms?
- use as an alias or function or with Taskfile, prevent Task from throwing an error for non-running vms
echo "[running]" $(virsh list --name) | xargs printf "%s\n" > ~/.local/tmp/inventory
ansible -i ~/.local/tmp/inventory -a 'uptime' running