Skip to content

Commit

Permalink
change the probe port name to make the language more generic
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobTanenbaum committed Mar 19, 2018
1 parent 1f93335 commit 3b65bf9
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions pkg/oc/admin/router/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,7 @@ const (
defaultPorts = "80:80,443:443"

// Default stats and healthz port.
defaultStatsPort = 1936
defaultHealthzPort = defaultStatsPort
defaultStatsPort = 1936
)

// NewCmdRouter implements the OpenShift CLI router command.
Expand Down Expand Up @@ -441,16 +440,16 @@ func generateProbeConfigForRouter(path string, cfg *RouterConfig, ports []kapi.C

if cfg.Type == "haproxy-router" {
probe = &kapi.Probe{}
healthzPort := defaultHealthzPort
probePort := defaultStatsPort
if cfg.StatsPort > 0 {
healthzPort = cfg.StatsPort
probePort = cfg.StatsPort
}

probe.Handler.HTTPGet = &kapi.HTTPGetAction{
Path: path,
Port: intstr.IntOrString{
Type: intstr.Int,
IntVal: int32(healthzPort),
IntVal: int32(probePort),
},
}

Expand Down

0 comments on commit 3b65bf9

Please sign in to comment.