Revision 90858bda snf-cyclades-app/synnefo/logic/backend.py
b/snf-cyclades-app/synnefo/logic/backend.py | ||
---|---|---|
140 | 140 |
if status == "success": |
141 | 141 |
if state_for_success is not None: |
142 | 142 |
vm.operstate = state_for_success |
143 |
if nics is not None: |
|
144 |
# Update the NICs of the VM |
|
145 |
_process_net_status(vm, etime, nics) |
|
146 | 143 |
if beparams: |
147 | 144 |
# Change the flavor of the VM |
148 | 145 |
_process_resize(vm, beparams) |
... | ... | |
153 | 150 |
# in reversed order. |
154 | 151 |
vm.backendtime = etime |
155 | 152 |
|
153 |
if status in ["success", "error", "canceled"] and nics is not None: |
|
154 |
# Update the NICs of the VM |
|
155 |
_process_net_status(vm, etime, nics) |
|
156 |
|
|
156 | 157 |
# Special case: if OP_INSTANCE_CREATE fails --> ERROR |
157 | 158 |
if opcode == 'OP_INSTANCE_CREATE' and status in ('canceled', 'error'): |
158 | 159 |
vm.operstate = 'ERROR' |
Also available in: Unified diff