Browse Source

Merge pull request #232 from erikwilson/load-balancer-port-name-size-limit-fix

Short port names for service load balancer
pull/244/head
Darren Shepherd 6 years ago committed by GitHub
parent
commit
cfc8ab54f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      pkg/servicelb/controller.go

7
pkg/servicelb/controller.go

@ -272,11 +272,8 @@ func (h *handler) newDeployment(svc *core.Service) (*apps.Deployment, error) {
},
}
for i, port := range svc.Spec.Ports {
portName := port.Name
if portName == "" {
portName = fmt.Sprintf("port-%d", i)
}
for _, port := range svc.Spec.Ports {
portName := fmt.Sprintf("lb-port-%d", port.Port)
container := core.Container{
Name: portName,
Image: image,

Loading…
Cancel
Save