Browse Source

Make use of GetAllManagedPluginsForCap to avoid loading v1-plugins

Read this for more details : https://github.com/docker/docker/pull/29665

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Madhu Venugopal 8 years ago
parent
commit
c6dfc70b33
2 changed files with 2 additions and 2 deletions
  1. 1 1
      libnetwork/drivers/remote/driver.go
  2. 1 1
      libnetwork/ipams/remote/remote.go

+ 1 - 1
libnetwork/drivers/remote/driver.go

@@ -46,7 +46,7 @@ func Init(dc driverapi.DriverCallback, config map[string]interface{}) error {
 	handleFunc := plugins.Handle
 	if pg := dc.GetPluginGetter(); pg != nil {
 		handleFunc = pg.Handle
-		activePlugins, _ := pg.GetAllByCap(driverapi.NetworkPluginEndpointType)
+		activePlugins := pg.GetAllManagedPluginsByCap(driverapi.NetworkPluginEndpointType)
 		for _, ap := range activePlugins {
 			newPluginHandler(ap.Name(), ap.Client())
 		}

+ 1 - 1
libnetwork/ipams/remote/remote.go

@@ -50,7 +50,7 @@ func Init(cb ipamapi.Callback, l, g interface{}) error {
 	handleFunc := plugins.Handle
 	if pg := cb.GetPluginGetter(); pg != nil {
 		handleFunc = pg.Handle
-		activePlugins, _ := pg.GetAllByCap(ipamapi.PluginEndpointType)
+		activePlugins := pg.GetAllManagedPluginsByCap(ipamapi.PluginEndpointType)
 		for _, ap := range activePlugins {
 			newPluginHandler(ap.Name(), ap.Client())
 		}