Skip to content

Commit

Permalink
Fix the path on loki helm install
Browse files Browse the repository at this point in the history
Signed-off-by: Alistair Hey <alistair@heyal.co.uk>
  • Loading branch information
Waterdrips authored and alexellis committed Jun 19, 2020
1 parent 877b5e2 commit 7781e43
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/helm/helm.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,11 @@ func AddHelmRepo(name, url string, update, helm3 bool) error {
if helm3 {
subdir = "helm3"
}

if index := strings.Index(name, "/"); index > -1 {
name = name[:index]
}

task := execute.ExecTask{
Command: fmt.Sprintf("%s repo add %s %s", env.LocalBinary("helm", subdir), name, url),
Env: os.Environ(),
Expand Down Expand Up @@ -193,7 +198,6 @@ func FetchChart(chart, version string, helm3 bool) error {
if mkErr != nil {
return mkErr
}

task := execute.ExecTask{
Command: fmt.Sprintf("%s fetch %s --untar=true --untardir %s%s", env.LocalBinary("helm", subdir), chart, chartsPath, versionStr),
Env: os.Environ(),
Expand Down

0 comments on commit 7781e43

Please sign in to comment.