Autoremove vm based to last login

bit2gb

Well-Known Member
Jul 20, 2016
84
2
48
29
Hello guys i want to find a solution for the next flow:
I create a vm windows with qemu guest allready installed
After 3 4 ..n days if any user don't login or make some activity into that vm i want to automaticaly remove that vm.
Exist some solution for my situation?
Thanks,
Alin
 
I do not think that removing a VM based on inactivity is good idea, too risky.
 
we do not provide this, but you can build it by your own (using the API).
 
so i want to run this command
net user username | findstr /B /C:"Last logon" via proxmox terminal and get result.
How can i do this?