Skip to content

Commit de84c1c

Browse files
committed
engine: honour bypass VLAN id/range for L2 networks
Commit e894238d904a9c49c1140371f612a51d251efc1 (apache#3899) allowed private gateways to bypass vlan check while refactoring it did not cover the case for L2 but only shared network. This fix will re-enable honouring the bypass vlan check option for L2 guest network (in addition to the Shared networks). Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
1 parent b68be66 commit de84c1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2529,7 +2529,7 @@ public Network doInTransaction(final TransactionStatus status) {
25292529
* @param ntwkOff network offering
25302530
*/
25312531
private boolean hasGuestBypassVlanOverlapCheck(final boolean bypassVlanOverlapCheck, final NetworkOfferingVO ntwkOff, final boolean isPrivateNetwork) {
2532-
return bypassVlanOverlapCheck && (ntwkOff.getGuestType() == GuestType.Shared || isPrivateNetwork);
2532+
return bypassVlanOverlapCheck && (ntwkOff.getGuestType() == GuestType.Shared || ntwkOff.getGuestType() == GuestType.L2 || isPrivateNetwork);
25332533
}
25342534

25352535
/**

0 commit comments

Comments
 (0)