Mahmood Ali
2fb5e35012
Merge pull request #4950 from hashicorp/b-exc-libcontainer-kill
...
executor: kill all container processes
2018-12-08 09:52:42 -05:00
Mahmood Ali
e9dc31c68f
executor: Keep 0.8.6 exit code for wait() failures
...
0.8.6 uses exit code 1 when `proc.Wait()` fails: https://github.com/hashicorp/nomad/blob/v0.8.6/client/driver/executor/executor.go#L442
2018-12-04 19:38:25 -05:00
Mahmood Ali
f6efac6c12
no t.Parallel() in excutor table driven tests ( #4948 )
...
When `t.Parallel()` is used inside a `t.Run()` sub-set, the closure
doesn't behave as expected, and some cases effectively get skipped.
More details can be found in
https://gist.github.com/posener/92a55c4cd441fc5e5e85f27bca008721
2018-12-04 09:04:04 -05:00
Mahmood Ali
781d8558f2
Kill all container processes on shutdown
...
Currently, libcontainer-based executor, upon shutdown, kills the
container initial process. The children of the killed process remain
running, and the executor is never marked as terminated until they do.
Also, fix a case where we treat processes as successful, when
`proc.Wait()` fails. In some attempts, I was getting "waitid no child
processes" errors and such error shouldn't get process to be considered
successful.
2018-12-03 20:40:49 -05:00
Mahmood Ali
813f0a2282
libcontainer to manage /dev and /proc ( #4945 )
...
libcontainer already manages `/dev`, overriding task_dir - so let's use it for `/proc` as well and remove deadcode.
2018-12-03 10:41:01 -05:00
Danielle Tomlinson
03db4cf82d
client: Rename drivers/shared/env => client/taskenv
2018-11-30 12:18:39 +01:00
Danielle Tomlinson
756325bcbd
client: Merge driver/shared/structs and client/structs
2018-11-30 10:56:45 +01:00
Danielle Tomlinson
23197ec6b4
drivers: Create drivers/shared/structs
...
This creates a drivers/shared/structs package and moves the buffer size
checks into it.
2018-11-30 10:46:13 +01:00
Danielle Tomlinson
d2136e0aa7
drivers: Move client/drivers/executor to drivers/shared/executor
2018-11-30 10:46:13 +01:00