mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-04 18:00:08 +00:00
fix inconsistency in updating hns policy
This commit is contained in:
parent
c1ad6e961a
commit
524de768bb
@ -517,15 +517,14 @@ func CleanupLeftovers() (encounteredError bool) {
|
|||||||
|
|
||||||
func (svcInfo *serviceInfo) cleanupAllPolicies(endpoints []*endpointsInfo) {
|
func (svcInfo *serviceInfo) cleanupAllPolicies(endpoints []*endpointsInfo) {
|
||||||
Log(svcInfo, "Service Cleanup", 3)
|
Log(svcInfo, "Service Cleanup", 3)
|
||||||
if svcInfo.policyApplied {
|
// Skip the svcInfo.policyApplied check to remove all the policies
|
||||||
svcInfo.deleteAllHnsLoadBalancerPolicy()
|
svcInfo.deleteAllHnsLoadBalancerPolicy()
|
||||||
// Cleanup Endpoints references
|
// Cleanup Endpoints references
|
||||||
for _, ep := range endpoints {
|
for _, ep := range endpoints {
|
||||||
ep.Cleanup()
|
ep.Cleanup()
|
||||||
}
|
|
||||||
|
|
||||||
svcInfo.policyApplied = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
svcInfo.policyApplied = false
|
||||||
}
|
}
|
||||||
|
|
||||||
func (svcInfo *serviceInfo) deleteAllHnsLoadBalancerPolicy() {
|
func (svcInfo *serviceInfo) deleteAllHnsLoadBalancerPolicy() {
|
||||||
|
Loading…
Reference in New Issue
Block a user