Revision 05d401cf snf-cyclades-app/synnefo/api/servers.py
b/snf-cyclades-app/synnefo/api/servers.py | ||
---|---|---|
513 | 513 |
|
514 | 514 |
# No actions to deleted VMs |
515 | 515 |
if vm.deleted: |
516 |
raise VirtualMachine.DeletedError
|
|
516 |
raise faults.BadRequest("VirtualMachine has been deleted.")
|
|
517 | 517 |
|
518 | 518 |
# No actions to machines being built. They may be destroyed, however. |
519 | 519 |
if vm.operstate == 'BUILD' and action != 'DESTROY': |
520 |
raise VirtualMachine.BuildingError
|
|
520 |
raise faults.BuildInProgress("Server is being build.")
|
|
521 | 521 |
|
522 | 522 |
vm.action = action |
523 | 523 |
vm.backendjobid = None |
Also available in: Unified diff