Fixing the exec script check to run within the chroot

This commit is contained in:
Diptanu Choudhury
2016-03-25 17:48:05 -07:00
parent d4a5f075dd
commit 6ee99af452
2 changed files with 7 additions and 1 deletions

View File

@@ -58,7 +58,7 @@ func TestExecScriptCheckWithIsolation(t *testing.T) {
id: "foo",
cmd: "/bin/echo",
args: []string{"hello", "world"},
taskDir: "/tmp",
taskDir: ctx.AllocDir.TaskDirs["web"],
FSIsolation: true,
}

View File

@@ -12,6 +12,12 @@ import (
func (e *UniversalExecutor) LaunchSyslogServer(ctx *ExecutorContext) (*SyslogServerState, error) {
e.ctx = ctx
// configuring the task dir
if err := e.configureTaskDir(); err != nil {
return nil, err
}
e.syslogChan = make(chan *logging.SyslogMessage, 2048)
l, err := e.getListener(e.ctx.PortLowerBound, e.ctx.PortUpperBound)
if err != nil {