Skip to content

Commit

Permalink
feat(nginx): optimize livenessProbe and args of ingress controller (#73)
Browse files Browse the repository at this point in the history
  • Loading branch information
caicloud-bot authored Nov 30, 2018
1 parent 5fa270b commit f3eb518
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/proxy/proxies/nginx/ingress.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ func (f *nginx) generateDeployment(lb *lbapi.LoadBalancer) *appsv1.Deployment {
ObjectMeta: metav1.ObjectMeta{
Name: lb.Name + proxyNameSuffix + "-" + lbutil.RandStringBytesRmndr(5),
Labels: labels,

OwnerReferences: []metav1.OwnerReference{
{
APIVersion: api.ControllerKind.GroupVersion().String(),
Expand Down Expand Up @@ -163,6 +162,7 @@ func (f *nginx) generateDeployment(lb *lbapi.LoadBalancer) *appsv1.Deployment {
"--status-port=" + strconv.Itoa(ingressStatusPort),
"--annotations-prefix=" + f.annotationPrefix,
"--enable-ssl-passthrough",
"--enable-ssl-chain-completion=false",
},
ReadinessProbe: &v1.Probe{
Handler: v1.Handler{
Expand All @@ -174,6 +174,8 @@ func (f *nginx) generateDeployment(lb *lbapi.LoadBalancer) *appsv1.Deployment {
},
},
LivenessProbe: &v1.Probe{
// wait 120s before liveness probe is initiated
InitialDelaySeconds: 120,
Handler: v1.Handler{
HTTPGet: &v1.HTTPGetAction{
Path: healthCheckPath,
Expand Down

0 comments on commit f3eb518

Please sign in to comment.