Skip to content

Commit

Permalink
Merge pull request #14 from hhiew/patch-1
Browse files Browse the repository at this point in the history
Update executor.go
  • Loading branch information
apptut authored Nov 25, 2022
2 parents 0424939 + a600001 commit 919db3c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/executor/executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ func Exec(processFile, customLogFile, name, extArgs string, user *user.User, aut
uid, _ := strconv.Atoi(user.Uid)
gid, _ := strconv.Atoi(user.Gid)

lastSepIdx := strings.LastIndex(processFile, string(os.PathSeparator))
attr := &os.ProcAttr{
Dir: processFile[0 : lastSepIdx+1],
Env: os.Environ(),
Files: []*os.File{nil, logOutput, logOutput},
Sys: &syscall.SysProcAttr{
Expand Down

0 comments on commit 919db3c

Please sign in to comment.