Skip to content

Commit

Permalink
fix: 避免忽略本地allow any云上deny any安全组规则同步
Browse files Browse the repository at this point in the history
  • Loading branch information
Qu Xuan committed May 21, 2020
1 parent daf9db8 commit c8ba52c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/compute/regiondrivers/managedvirtual.go
Original file line number Diff line number Diff line change
Expand Up @@ -1545,7 +1545,7 @@ func (self *SManagedVirtualizationRegionDriver) RequestSyncSecurityGroup(ctx con
sort.Sort(outRules)
_inAllowList := inRules.AllowList()
_outAllowList := outRules.AllowList()
if inAllowList.Equals(_inAllowList) && outAllowList.Equals(_outAllowList) {
if inAllowList.Equals(_inAllowList) && outAllowList.Equals(_outAllowList) && (len(_inAllowList) > 0 && len(_outAllowList) > 0) { // 避免单个deny any的allowList为空,导致安全组规则未同步
return cache.ExternalId, nil
}

Expand Down

0 comments on commit c8ba52c

Please sign in to comment.