Skip to content

Commit

Permalink
fix(v1): rm bash absolute path (#1594)
Browse files Browse the repository at this point in the history
fix: rm bash path prefix

Signed-off-by: Keming <kemingyang@tensorchord.ai>
  • Loading branch information
kemingy committed May 8, 2023
1 parent aaaa931 commit 8ab73d8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/lang/ir/v1/shell.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ deleted = "x"
)

func (g *generalGraph) compileShell(root llb.State) (_ llb.State, err error) {
g.RuntimeEnviron["SHELL"] = "/usr/bin/bash"
g.RuntimeEnviron["SHELL"] = "bash"
if g.Shell == shellZSH {
g.RuntimeEnviron["SHELL"] = "/usr/bin/zsh"
root, err = g.compileZSH(root)
Expand Down
2 changes: 1 addition & 1 deletion pkg/lang/ir/v1/system.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ func (g generalGraph) compileRun(root llb.State) llb.State {
sb.WriteString(c + "\n")
}

cmdStr := fmt.Sprintf("/usr/bin/bash -c '%s'", sb.String())
cmdStr := fmt.Sprintf("bash -c '%s'", sb.String())
logrus.WithField("command", cmdStr).Debug("compile run command")
// Mount the build context into the build process.
// TODO(gaocegege): Maybe we should make it readonly,
Expand Down

0 comments on commit 8ab73d8

Please sign in to comment.