Do not delete VMs in the HOLD state.

If a VM is in the HOLD state do not transition it to the DELETE state.
This should allow you to set a VM to the HOLD state before tests have
completed and the VM will not be deleted.

Change-Id: I8cc0ca408b4ccf5951399e27c0bfc518fa8ebd1d
This commit is contained in:
Clark Boylan
2012-09-05 09:50:16 -07:00
parent 0149935481
commit e0f30bb460

View File

@@ -33,7 +33,8 @@ def main():
db = vmdatabase.VMDatabase()
machine = db.getMachineByJenkinsName(NODE_NAME)
machine.state = vmdatabase.DELETE
if machine.state != vmdatabase.HOLD:
machine.state = vmdatabase.DELETE
if __name__ == '__main__':