import "github.com/docker/docker/plugin/v2"
plugin.go plugin_linux.go settable.go
type ErrInadequateCapability struct {
// contains filtered or unexported fields
}
ErrInadequateCapability indicates that the plugin did not have the requested capability.
func (e ErrInadequateCapability) Error() string
type Plugin struct { PluginObj types.Plugin `json:"plugin"` // todo: embed struct Rootfs string // TODO: make private Config digest.Digest Blobsums []digest.Digest Manifest digest.Digest SwarmServiceID string // contains filtered or unexported fields }
Plugin represents an individual plugin.
Acquire increments the plugin's reference count This should be followed up by `Release()` when the plugin is no longer in use.
AddRefCount adds to reference count.
Addr returns the net.Addr to use to connect to the plugin socket
Client returns the plugin client. Deprecated: use p.Addr() and manually create the client
FilterByCap query the plugin for a given capability.
GetID returns the plugin's ID.
GetRefCount returns the reference count.
GetSocket returns the plugin socket.
func (p *Plugin) GetTypes() []types.PluginInterfaceType
GetTypes returns the interface types of a plugin.
InitEmptySettings initializes empty settings for a plugin.
InitSpec creates an OCI spec from the plugin's config.
IsEnabled returns the active state of the plugin.
IsV1 returns true for V1 plugins and false otherwise.
Name returns the plugin name.
Protocol is the protocol that should be used for interacting with the plugin.
Release decrements the plugin's reference count This should only be called when the plugin is no longer in use, e.g. with via `Acquire()` or getter.Get("name", "type", plugingetter.Acquire)
ScopedPath returns the path scoped to the plugin rootfs
Set is used to pass arguments to the plugin.
SetAddr sets the plugin address which can be used for dialing the plugin.
SetPClient set the plugin client. Deprecated: Hardcoded plugin client is deprecated
SetSpecOptModifier sets the function to use to modify the generated runtime spec.
SetTimeout sets the timeout to use for dialing.
Timeout gets the currently configured connection timeout. This should be used when dialing the plugin.
Package v2 imports 17 packages (graph) and is imported by 300 packages. Updated 2020-04-25. Refresh now. Tools for package owners.