Merge pull request #388 from runcom/must-bundle-path
execution/oci: validate bundle path
This commit is contained in:
commit
58640c9603
1 changed files with 3 additions and 0 deletions
|
@ -37,6 +37,9 @@ type OCIRuntime struct {
|
|||
}
|
||||
|
||||
func (r *OCIRuntime) Create(ctx context.Context, id string, o execution.CreateOpts) (container *execution.Container, err error) {
|
||||
if o.Bundle == "" {
|
||||
return nil, errors.New("bundle path cannot be an empty string")
|
||||
}
|
||||
oio, err := newOIO(o.Stdin, o.Stdout, o.Stderr, o.Console)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
Loading…
Reference in a new issue