Runtime v2

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby
2018-07-09 13:27:52 -04:00
parent 6de11ab973
commit da1b5470cd
78 changed files with 9836 additions and 652 deletions

View File

@@ -23,9 +23,10 @@ import (
)
type clientOpts struct {
defaultns string
services *services
dialOptions []grpc.DialOption
defaultns string
defaultRuntime string
services *services
dialOptions []grpc.DialOption
}
// ClientOpt allows callers to set options on the containerd client
@@ -42,6 +43,14 @@ func WithDefaultNamespace(ns string) ClientOpt {
}
}
// WithDefaultRuntime sets the default runtime on the client
func WithDefaultRuntime(rt string) ClientOpt {
return func(c *clientOpts) error {
c.defaultRuntime = rt
return nil
}
}
// WithDialOpts allows grpc.DialOptions to be set on the connection
func WithDialOpts(opts []grpc.DialOption) ClientOpt {
return func(c *clientOpts) error {