Commit 06fbc720 authored by SataQiu's avatar SataQiu

refactor: using tiller probe port constant

Signed-off-by: 's avatarSataQiu <qiushida@beyondcent.com>
parent c645373e
...@@ -228,7 +228,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) { ...@@ -228,7 +228,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) {
ImagePullPolicy: opts.pullPolicy(), ImagePullPolicy: opts.pullPolicy(),
Ports: []v1.ContainerPort{ Ports: []v1.ContainerPort{
{ContainerPort: environment.DefaultTillerPort, Name: "tiller"}, {ContainerPort: environment.DefaultTillerPort, Name: "tiller"},
{ContainerPort: 44135, Name: "http"}, {ContainerPort: environment.DefaultTillerProbePort, Name: "http"},
}, },
Env: []v1.EnvVar{ Env: []v1.EnvVar{
{Name: "TILLER_NAMESPACE", Value: opts.Namespace}, {Name: "TILLER_NAMESPACE", Value: opts.Namespace},
...@@ -238,7 +238,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) { ...@@ -238,7 +238,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) {
Handler: v1.Handler{ Handler: v1.Handler{
HTTPGet: &v1.HTTPGetAction{ HTTPGet: &v1.HTTPGetAction{
Path: "/liveness", Path: "/liveness",
Port: intstr.FromInt(44135), Port: intstr.FromInt(environment.DefaultTillerProbePort),
}, },
}, },
InitialDelaySeconds: 1, InitialDelaySeconds: 1,
...@@ -248,7 +248,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) { ...@@ -248,7 +248,7 @@ func generateDeployment(opts *Options) (*v1beta1.Deployment, error) {
Handler: v1.Handler{ Handler: v1.Handler{
HTTPGet: &v1.HTTPGetAction{ HTTPGet: &v1.HTTPGetAction{
Path: "/readiness", Path: "/readiness",
Port: intstr.FromInt(44135), Port: intstr.FromInt(environment.DefaultTillerProbePort),
}, },
}, },
InitialDelaySeconds: 1, InitialDelaySeconds: 1,
......
...@@ -75,7 +75,7 @@ const ( ...@@ -75,7 +75,7 @@ const (
var ( var (
grpcAddr = flag.String("listen", fmt.Sprintf(":%v", environment.DefaultTillerPort), "address:port to listen on") grpcAddr = flag.String("listen", fmt.Sprintf(":%v", environment.DefaultTillerPort), "address:port to listen on")
probeAddr = flag.String("probe-listen", ":44135", "address:port to listen on for probes") probeAddr = flag.String("probe-listen", fmt.Sprintf(":%v", environment.DefaultTillerProbePort), "address:port to listen on for probes")
enableTracing = flag.Bool("trace", false, "enable rpc tracing") enableTracing = flag.Bool("trace", false, "enable rpc tracing")
store = flag.String("storage", storageConfigMap, "storage driver to use. One of 'configmap', 'memory', or 'secret'") store = flag.String("storage", storageConfigMap, "storage driver to use. One of 'configmap', 'memory', or 'secret'")
remoteReleaseModules = flag.Bool("experimental-release", false, "enable experimental release modules") remoteReleaseModules = flag.Bool("experimental-release", false, "enable experimental release modules")
......
...@@ -44,6 +44,9 @@ const ( ...@@ -44,6 +44,9 @@ const (
// DefaultTillerPort defines the default port tiller listen on for client traffic // DefaultTillerPort defines the default port tiller listen on for client traffic
DefaultTillerPort = 44134 DefaultTillerPort = 44134
// DefaultTillerProbePort defines the default port to listen on for probes
DefaultTillerProbePort = 44135
// GoTplEngine is the name of the Go template engine, as registered in the EngineYard. // GoTplEngine is the name of the Go template engine, as registered in the EngineYard.
GoTplEngine = "gotpl" GoTplEngine = "gotpl"
) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment