CLOUDSTACK-6232 allow expansion of ip on isolated networks as well

This commit is contained in:
Daan Hoogland 2014-03-12 19:36:11 +01:00
parent 0379dbb489
commit edf97ac86c
1 changed files with 4 additions and 3 deletions

View File

@ -2643,9 +2643,10 @@ ConfigurationManagerImpl extends ManagerBase implements ConfigurationManager, Co
networkId = network.getId();
zoneId = network.getDataCenterId();
}
} else if (network.getGuestType() == null || network.getGuestType() == Network.GuestType.Isolated) {
throw new InvalidParameterValueException("Can't create direct vlan for network id=" + networkId
+ " with type: " + network.getGuestType());
} else if (network.getGuestType() == null ||
(network.getGuestType() == Network.GuestType.Isolated
&& _ntwkOffServiceMapDao.areServicesSupportedByNetworkOffering(network.getNetworkOfferingId(), Service.SourceNat))) {
throw new InvalidParameterValueException("Can't create direct vlan for network id=" + networkId + " with type: " + network.getGuestType());
}
}