Skip to content

Commit 2710f59

Browse files
committed
server: fix scale for dummy template ingested vm
For vm import, dummy template can be used - https://docs.cloudstack.apache.org/en/latest/adminguide/virtual_machines.html#dummy-template Named as system-default-vm-import-dummy-template.iso, the template is marked as removed in the CloudStack DB. For scale operation while trying to find vm template, server needs to find in all templates including removed. Fixes #5096 Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent b258232 commit 2710f59

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -924,7 +924,7 @@ public VolumeVO resizeVolume(ResizeVolumeCmd cmd) throws ResourceAllocationExcep
924924
if (newDiskOffering == null) {
925925
Long templateId = volume.getTemplateId();
926926
if (templateId != null) {
927-
VMTemplateVO template = _templateDao.findById(templateId);
927+
VMTemplateVO template = _templateDao.findByIdIncludingRemoved(templateId);
928928
format = template.getFormat();
929929
}
930930

0 commit comments

Comments
 (0)