Xapi#startVmOnCd(): fix for HVM (fix vatesfr/xo-web#794).

This commit is contained in:
Julien Fontanet 2016-03-03 09:43:12 +01:00
parent 8e3484bb17
commit 52073e79fa

View File

@ -1721,17 +1721,17 @@ export default class Xapi extends XapiBase {
const vm = this.getObject(vmId)
if (isVmHvm(vm)) {
const bootOrder = vm.HVM_boot_params
const { order } = vm.HVM_boot_params
await this._setObjectProperties(vm, {
HVM_boot_params: 'd'
await this._updateObjectMapProperty(vm, 'HVM_boot_params', {
order: 'd'
})
try {
await this._startVm(vm)
} finally {
await this._setObjectProperties(vm, {
HVM_boot_params: bootOrder
await this._updateObjectMapProperty(vm, 'HVM_boot_params', {
order
})
}
} else {