Merge pull request #391 from mrunalp/exec_validate

Validate process configuration for runc exec
This commit is contained in:
Alexander Morozov 2015-11-12 16:35:44 -08:00
commit 1df35060e4
1 changed files with 3 additions and 0 deletions

View File

@ -23,6 +23,9 @@ var execCommand = cli.Command{
if os.Geteuid() != 0 {
logrus.Fatal("runc should be run as root")
}
if config.Args == nil {
logrus.Fatal("args missing in process configuration")
}
status, err := execProcess(context, config)
if err != nil {
logrus.Fatalf("exec failed: %v", err)