containerd/vendor/github.com/containerd/go-runc/command_other.go
Justin Cormack 6a571ecd40 Portability fixes for containerd shim
Update go-runc to master with portability fixes.

Subreaper only exists on Linux, and only Linux runs the shim in a
mount namespace.

With these changes the shim compiles on Darwin, which means the
whole build compiles without errors now.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2017-05-16 17:13:32 +01:00

17 lines
292 B
Go

// +build !linux
package runc
import (
"context"
"os/exec"
)
func (r *Runc) command(context context.Context, args ...string) *exec.Cmd {
command := r.Command
if command == "" {
command = DefaultCommand
}
return exec.CommandContext(context, command, append(r.args(), args...)...)
}