Add task to gracefully terminate domain class instances
This commit is contained in:
parent
60b5156c37
commit
dd8b7d69cc
3
pvc.py
3
pvc.py
|
@ -767,6 +767,9 @@ def undefine_vm(dom_name, dom_uuid):
|
||||||
click.echo('Waiting for cluster to update.')
|
click.echo('Waiting for cluster to update.')
|
||||||
time.sleep(3)
|
time.sleep(3)
|
||||||
|
|
||||||
|
# Gracefully terminate the class instances
|
||||||
|
transaction.set_data('/domains/{}/state'.format(dom_uuid), 'delete'.encode('ascii'))
|
||||||
|
time.sleep(2)
|
||||||
# Delete the configurations
|
# Delete the configurations
|
||||||
click.echo('Undefining VM "{}".'.format(dom_uuid))
|
click.echo('Undefining VM "{}".'.format(dom_uuid))
|
||||||
transaction = zk.transaction()
|
transaction = zk.transaction()
|
||||||
|
|
Loading…
Reference in New Issue