Skip to content

Commit

Permalink
searching only for run.sh on docker pre run (ZupIT#598)
Browse files Browse the repository at this point in the history
Signed-off-by: JoaoDanielRufino <[email protected]>
Signed-off-by: Bruno N. Melo <[email protected]>
  • Loading branch information
JoaoDanielRufino authored and brunonmelo committed Nov 12, 2020
1 parent 9b7795e commit b5c38b1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions pkg/formula/formula.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,10 @@ func (d *Definition) TmpWorkDirPath(home string) string {
return filepath.Join(home, TmpDir, u)
}

func (d *Definition) UnixBinFilePath(fPath string) string {
return filepath.Join(fPath, BinDir, BinUnix)
}

// BinFilePath builds the bin file path from formula path
func (d *Definition) BinFilePath(fPath string) string {
return filepath.Join(fPath, BinDir, d.BinName())
Expand Down
2 changes: 1 addition & 1 deletion pkg/formula/runner/docker/pre_run.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (pr PreRunManager) PreRun(def formula.Definition) (formula.Setup, error) {
return formula.Setup{}, err
}

binFilePath := def.BinFilePath(formulaPath)
binFilePath := def.UnixBinFilePath(formulaPath)
if !pr.file.Exists(binFilePath) {
s := spinner.StartNew("Building formula...")
time.Sleep(2 * time.Second)
Expand Down

0 comments on commit b5c38b1

Please sign in to comment.