mirror of https://github.com/k3s-io/k3s
Merge pull request #56688 from karataliu/fix_azure_internallb_static
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Fix static IP issue for Azure internal LB **What this PR does / why we need it**: Fix regression for Azure internal LB with static IP support **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*: Fixes #56686 **Special notes for your reviewer**: **Release note**: ```release-note ```pull/6/head
commit
86ff044d84
|
@ -1134,9 +1134,13 @@ func deduplicate(collection *[]string) *[]string {
|
|||
func (az *Cloud) reconcilePublicIP(clusterName string, service *v1.Service, wantLb bool) (*network.PublicIPAddress, error) {
|
||||
isInternal := requiresInternalLoadBalancer(service)
|
||||
serviceName := getServiceName(service)
|
||||
desiredPipName, err := az.determinePublicIPName(clusterName, service)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
var desiredPipName string
|
||||
var err error
|
||||
if !isInternal && wantLb {
|
||||
desiredPipName, err = az.determinePublicIPName(clusterName, service)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
|
||||
pips, err := az.ListPIPWithRetry()
|
||||
|
|
Loading…
Reference in New Issue