CLOUDSTACK-2991: [PortableIPRange] CS should not allow portable IP with

sourceNAT service on it

if a portable ip is first IP associated with a non-VPC network, then its
being considered as source nat IP. This fix adds exemption for portable
IP not to be considred for source nat.
This commit is contained in:
Murali Reddy 2013-07-30 15:34:04 +05:30
parent c93c321b3b
commit b5f33ae0d8
1 changed files with 2 additions and 1 deletions

View File

@ -954,7 +954,8 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L
boolean isSourceNat = false;
if (!sharedSourceNat) {
if (getExistingSourceNatInNetwork(owner.getId(), networkId) == null) {
if (network.getGuestType() == GuestType.Isolated && network.getVpcId() == null) {
if (network.getGuestType() == GuestType.Isolated && network.getVpcId() == null &&
!ipToAssoc.isPortable()) {
isSourceNat = true;
}
}