Skip to content

Commit

Permalink
Merge pull request #671 from TrekkieCoder/main
Browse files Browse the repository at this point in the history
PR - Added LB annotations to skip adding local VIP
  • Loading branch information
UltraInstinct14 authored May 9, 2024
2 parents 7d61325 + 1eda892 commit 67599f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/loxinet/rules.go
Original file line number Diff line number Diff line change
Expand Up @@ -1189,7 +1189,7 @@ func (R *RuleH) unFoldRecursiveEPs(r *ruleEnt) {

// addVIPSys - system specific operations for VIPs of a LB rule
func (R *RuleH) addVIPSys(r *ruleEnt) {
if !strings.Contains(r.name, "ipvs") {
if !strings.Contains(r.name, "ipvs") && !strings.Contains(r.name, "static") {
R.vipMap[r.tuples.l3Dst.addr.IP.String()]++

if R.vipMap[r.tuples.l3Dst.addr.IP.String()] == 1 {
Expand Down Expand Up @@ -1498,7 +1498,7 @@ func (R *RuleH) AddNatLbRule(serv cmn.LbServiceArg, servSecIPs []cmn.LbSecIPArg,

// deleteVIPSys - system specific operations for deleting VIPs of a LB rule
func (R *RuleH) deleteVIPSys(r *ruleEnt) {
if !strings.Contains(r.name, "ipvs") {
if !strings.Contains(r.name, "ipvs") && !strings.Contains(r.name, "static") {
R.vipMap[r.tuples.l3Dst.addr.IP.String()]--

if R.vipMap[r.tuples.l3Dst.addr.IP.String()] == 0 {
Expand Down

0 comments on commit 67599f6

Please sign in to comment.