Automation of virtual machine creation and deletion