|
@@ -4,6 +4,7 @@ package plugin
|
|
|
|
|
|
import (
|
|
|
"errors"
|
|
|
+ "fmt"
|
|
|
"io"
|
|
|
"net/http"
|
|
|
|
|
@@ -24,8 +25,11 @@ func (pm *Manager) Enable(name string, config *types.PluginEnableConfig) error {
|
|
|
}
|
|
|
|
|
|
// Inspect examines a plugin config
|
|
|
-func (pm *Manager) Inspect(name string) (tp types.Plugin, err error) {
|
|
|
- return tp, errNotSupported
|
|
|
+func (pm *Manager) Inspect(refOrID string) (tp types.Plugin, err error) {
|
|
|
+ // Even though plugin is not supported, we still want to return `not found`
|
|
|
+ // error so that `docker inspect` (without `--type` specified) returns correct
|
|
|
+ // `not found` message
|
|
|
+ return tp, fmt.Errorf("no such plugin name or ID associated with %q", refOrID)
|
|
|
}
|
|
|
|
|
|
// Privileges pulls a plugin config and computes the privileges required to install it.
|