Commit 9e0408fc authored by fibonacci1729's avatar fibonacci1729

fix(helm): fix for issue #680r

details: the host flag for install overrides the
TILLER_HOST env var. If neither are set,
host defaults to ":44134".
parent 8ae7eb7d
...@@ -73,16 +73,14 @@ func printRelease(rel *release.Release) { ...@@ -73,16 +73,14 @@ func printRelease(rel *release.Release) {
} }
func setupInstallEnv() { func setupInstallEnv() {
// note: TILLER_HOST envvar is // The 'host' flag takes precendence uber alles.
// acknowledged iff the host flag // If set, proceed with install using provided host
// does not override the default. // address. If unset, the 'TILLER_HOST' environment
// // variable (if set) is used, otherwise defaults to ":44134".
// bug: except that if the host flag happens to set the host to the same if tillerHost == "" {
// value as the defaultHost, the env var will be used instead. tillerHost = os.Getenv(hostEnvVar)
if tillerHost == defaultHost { if tillerHost == "" {
host := os.Getenv(hostEnvVar) tillerHost = defaultHost
if host != "" {
tillerHost = host
} }
} }
...@@ -90,7 +88,7 @@ func setupInstallEnv() { ...@@ -90,7 +88,7 @@ func setupInstallEnv() {
} }
func init() { func init() {
installCmd.Flags().StringVar(&tillerHost, "host", defaultHost, "address of tiller server") installCmd.Flags().StringVar(&tillerHost, "host", "", "address of tiller server (default \":44134\")")
installCmd.Flags().BoolVar(&installDryRun, "dry-run", false, "simulate an install") installCmd.Flags().BoolVar(&installDryRun, "dry-run", false, "simulate an install")
RootCommand.AddCommand(installCmd) RootCommand.AddCommand(installCmd)
......
hash: 998d87445fec0bd715fa5ccbcc227cb4997e56ceff58dc8eb53ea2e0cc84abfd hash: 206ac8a0bde06c910b7100ca5de782dc96728e29693af6671cf5a52d1942b9c9
updated: 2016-04-27T16:11:47.531200165-06:00 updated: 2016-05-11T16:15:47.057456197-06:00
imports: imports:
- name: bitbucket.org/ww/goautoneg - name: bitbucket.org/ww/goautoneg
version: 75cd24fc2f2c version: 75cd24fc2f2c
...@@ -352,4 +352,6 @@ imports: ...@@ -352,4 +352,6 @@ imports:
- pkg/controller/podautoscaler/metrics - pkg/controller/podautoscaler/metrics
- name: speter.net/go/exp/math/dec/inf - name: speter.net/go/exp/math/dec/inf
version: 42ca6cd68aa922bc3f32f1e056e61b65945d9ad7 version: 42ca6cd68aa922bc3f32f1e056e61b65945d9ad7
repo: git@github.com:go-inf/inf.git
vcs: git
devImports: [] devImports: []
...@@ -30,3 +30,6 @@ import: ...@@ -30,3 +30,6 @@ import:
- pkg/kubectl/cmd/util - pkg/kubectl/cmd/util
- pkg/kubectl/resource - pkg/kubectl/resource
- package: github.com/gosuri/uitable - package: github.com/gosuri/uitable
- package: speter.net/go/exp/math/dec/inf
vcs: git
repo: git@github.com:go-inf/inf.git
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