fix: `helmfile template | kubectl apply -f -` should work (#697)

Fixes #685
This commit is contained in:
KUOKA Yusuke 2019-06-16 16:56:56 +09:00 committed by GitHub
parent 3bf0f7d54e
commit f61334d9bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 2 deletions

View File

@ -95,7 +95,7 @@ func (helm *execer) UpdateDeps(chart string) error {
func (helm *execer) BuildDeps(chart string) error {
helm.logger.Infof("Building dependency %v", chart)
out, err := helm.exec([]string{"dependency", "build", chart}, map[string]string{})
helm.write(out)
helm.info(out)
return err
}
@ -139,7 +139,7 @@ func (helm *execer) DecryptSecret(context HelmContext, name string, flags ...str
preArgs := context.GetTillerlessArgs(helm.helmBinary)
env := context.getTillerlessEnv()
out, err := helm.exec(append(append(preArgs, "secrets", "dec", absPath), flags...), env)
helm.write(out)
helm.info(out)
if err != nil {
return "", err
}

View File

@ -93,6 +93,9 @@ ${helm} status --namespace=${test_ns} httpbin &> /dev/null && fail "release shou
info "Ensuring \"helmfile delete\" doesn't fail when no releases installed"
${helmfile} -f ${dir}/happypath.yaml delete || fail "\"helmfile delete\" shouldn't fail when there are no installed releases"
info "Ensuring \"helmfile template\" output does contain only YAML docs"
(${helmfile} -f ${dir}/happypath.yaml template | kubectl apply -f -) || fail "\"helmfile template | kubectl apply -f -\" shouldn't fail"
test_pass "happypath"