mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
[Vmware to KVM Migration] Preserve boot type and boot mode of instances to be migrated (#10975)
* [Vmware to KVM Migration] Preserve boot type and boot mode of instances to be migrated * Restore end of line * Extract lines to new method * Address review comments
This commit is contained in:
parent
eeb4d55e89
commit
a51a04efc2
@ -1188,6 +1188,8 @@ public class UnmanagedVMsManagerImpl implements UnmanagedVMsManager {
|
||||
allDetails.put(VmDetailConstants.KVM_VNC_PASSWORD, unmanagedInstance.getVncPassword());
|
||||
}
|
||||
|
||||
addImportingVMBootTypeAndModeDetails(unmanagedInstance.getBootType(), unmanagedInstance.getBootMode(), allDetails);
|
||||
|
||||
VirtualMachine.PowerState powerState = VirtualMachine.PowerState.PowerOff;
|
||||
if (unmanagedInstance.getPowerState().equals(UnmanagedInstanceTO.PowerState.PowerOn)) {
|
||||
powerState = VirtualMachine.PowerState.PowerOn;
|
||||
@ -1259,6 +1261,12 @@ public class UnmanagedVMsManagerImpl implements UnmanagedVMsManager {
|
||||
return userVm;
|
||||
}
|
||||
|
||||
private void addImportingVMBootTypeAndModeDetails(String bootType, String bootMode, Map<String, String> allDetails) {
|
||||
if (StringUtils.isNotBlank(bootType) && bootType.equalsIgnoreCase("uefi") && StringUtils.isNotBlank(bootMode)) {
|
||||
allDetails.put("UEFI", bootMode);
|
||||
}
|
||||
}
|
||||
|
||||
private HashMap<String, UnmanagedInstanceTO> getUnmanagedInstancesForHost(HostVO host, String instanceName, List<String> managedVms) {
|
||||
HashMap<String, UnmanagedInstanceTO> unmanagedInstances = new HashMap<>();
|
||||
if (host.isInMaintenanceStates()) {
|
||||
|
||||
@ -732,6 +732,18 @@
|
||||
<span v-else>{{ resource.webhookname || resource.webhookid }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="resource-detail-item" v-if="resource.boottype">
|
||||
<div class="resource-detail-item__label">{{ $t('label.boottype') }}</div>
|
||||
<div class="resource-detail-item__details">
|
||||
<span>{{ resource.boottype }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="resource-detail-item" v-if="resource.bootmode">
|
||||
<div class="resource-detail-item__label">{{ $t('label.bootmode') }}</div>
|
||||
<div class="resource-detail-item__details">
|
||||
<span>{{ resource.bootmode }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="resource-detail-item" v-if="resource.managementserverid">
|
||||
<div class="resource-detail-item__label">{{ $t('label.management.servers') }}</div>
|
||||
<div class="resource-detail-item__details">
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user