Merge pull request #533 from vmware-tanzu/eks-load-balancer-annotation
Add annotation to make the idle timeout be over 1 hour rather than 1 minute
This commit is contained in:
commit
608be8332e
@ -441,6 +441,9 @@ func (c *impersonatorConfigController) ensureLoadBalancerIsStarted(ctx context.C
|
||||
Name: c.generatedLoadBalancerServiceName,
|
||||
Namespace: c.namespace,
|
||||
Labels: c.labels,
|
||||
Annotations: map[string]string{
|
||||
"service.beta.kubernetes.io/aws-load-balancer-connection-idle-timeout": "4000", // AWS' default is to time out after 60 seconds idle. Prevent that.
|
||||
},
|
||||
},
|
||||
}
|
||||
plog.Info("creating load balancer for impersonation proxy",
|
||||
|
@ -882,6 +882,7 @@ func TestImpersonatorConfigControllerSync(t *testing.T) {
|
||||
r.Equal(corev1.ServiceTypeLoadBalancer, createdLoadBalancerService.Spec.Type)
|
||||
r.Equal("app-name", createdLoadBalancerService.Spec.Selector["app"])
|
||||
r.Equal(labels, createdLoadBalancerService.Labels)
|
||||
r.Equal(map[string]string{"service.beta.kubernetes.io/aws-load-balancer-connection-idle-timeout": "4000"}, createdLoadBalancerService.Annotations)
|
||||
}
|
||||
|
||||
var requireLoadBalancerWasDeleted = func(action coretesting.Action) {
|
||||
|
Loading…
Reference in New Issue
Block a user