mirror of
				https://github.com/apache/cloudstack.git
				synced 2025-11-04 00:02:37 +01:00 
			
		
		
		
	only check hypervisor type for security enabled advanced zone
This commit is contained in:
		
							parent
							
								
									8d1189c2ae
								
							
						
					
					
						commit
						9905f656a5
					
				@ -161,6 +161,7 @@ import com.cloud.vm.VMInstanceVO;
 | 
				
			|||||||
import com.cloud.vm.VirtualMachine.State;
 | 
					import com.cloud.vm.VirtualMachine.State;
 | 
				
			||||||
import com.cloud.vm.VirtualMachineManager;
 | 
					import com.cloud.vm.VirtualMachineManager;
 | 
				
			||||||
import com.cloud.vm.dao.VMInstanceDao;
 | 
					import com.cloud.vm.dao.VMInstanceDao;
 | 
				
			||||||
 | 
					import com.cloud.dc.DataCenter.NetworkType;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@Component
 | 
					@Component
 | 
				
			||||||
@Local({ ResourceManager.class, ResourceService.class })
 | 
					@Local({ ResourceManager.class, ResourceService.class })
 | 
				
			||||||
@ -444,7 +445,7 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager,
 | 
				
			|||||||
					+ cmd.getHypervisor() + " to a supported ");
 | 
										+ cmd.getHypervisor() + " to a supported ");
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if (zone.isSecurityGroupEnabled()) {
 | 
					        if (zone.isSecurityGroupEnabled() && zone.getNetworkType().equals(NetworkType.Advanced)) {
 | 
				
			||||||
            if (hypervisorType != HypervisorType.KVM && hypervisorType != HypervisorType.XenServer
 | 
					            if (hypervisorType != HypervisorType.KVM && hypervisorType != HypervisorType.XenServer
 | 
				
			||||||
                    && hypervisorType != HypervisorType.Simulator) {
 | 
					                    && hypervisorType != HypervisorType.Simulator) {
 | 
				
			||||||
                throw new InvalidParameterValueException("Don't support hypervisor type " + hypervisorType + " in advanced security enabled zone");
 | 
					                throw new InvalidParameterValueException("Don't support hypervisor type " + hypervisorType + " in advanced security enabled zone");
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user