|
@@ -685,10 +685,14 @@ func GetFwRulesOnIngressGateway(node models.Node) (rules []models.FwRule) {
|
|
if peer.StaticNode.ClientID == nodeI.StaticNode.ClientID || peer.IsUserNode {
|
|
if peer.StaticNode.ClientID == nodeI.StaticNode.ClientID || peer.IsUserNode {
|
|
continue
|
|
continue
|
|
}
|
|
}
|
|
- if nodeI.StaticNode.IngressGatewayID != node.ID.String() && peer.ID.String() != node.ID.String() {
|
|
|
|
|
|
+ if nodeI.StaticNode.IngressGatewayID != node.ID.String() &&
|
|
|
|
+ ((!peer.IsStatic && peer.ID.String() != node.ID.String()) ||
|
|
|
|
+ (peer.IsStatic && peer.StaticNode.IngressGatewayID != node.ID.String())) {
|
|
continue
|
|
continue
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+ if peer.IsStatic {
|
|
|
|
+ peer = peer.StaticNode.ConvertToStaticNode()
|
|
|
|
+ }
|
|
if ok, allowedPolicies := IsNodeAllowedToCommunicateV1(nodeI.StaticNode.ConvertToStaticNode(), peer, true); ok {
|
|
if ok, allowedPolicies := IsNodeAllowedToCommunicateV1(nodeI.StaticNode.ConvertToStaticNode(), peer, true); ok {
|
|
rules = append(rules, getFwRulesForNodeAndPeerOnGw(nodeI.StaticNode.ConvertToStaticNode(), peer, allowedPolicies)...)
|
|
rules = append(rules, getFwRulesForNodeAndPeerOnGw(nodeI.StaticNode.ConvertToStaticNode(), peer, allowedPolicies)...)
|
|
}
|
|
}
|