You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/08/03 15:12:33 UTC

[GitHub] [cloudstack] DaanHoogland commented on a change in pull request #5270: server: skip zone check for PERHOST iso during attachIso

DaanHoogland commented on a change in pull request #5270:
URL: https://github.com/apache/cloudstack/pull/5270#discussion_r681852199



##########
File path: server/src/main/java/com/cloud/template/TemplateManagerImpl.java
##########
@@ -1204,10 +1207,11 @@ public boolean attachIso(long isoId, long vmId, boolean forced) {
             throw new InvalidParameterValueException("Unable to find an ISO with id " + isoId);
         }
 
-        long dcId = vm.getDataCenterId();
-        VMTemplateZoneVO exists = _tmpltZoneDao.findByZoneTemplate(dcId, isoId);
-        if (null == exists) {
-            throw new InvalidParameterValueException("ISO is not available in the zone the VM is in.");
+        if (TemplateType.PERHOST.equals(iso.getTemplateType())) {

Review comment:
       if it was PERHOST we were not going to check, right? looks reversed here.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org