From d4d0b5c26833a622ef21503251a85c803a3bcc4f Mon Sep 17 00:00:00 2001 From: Brian Goff Date: Thu, 11 Jan 2018 14:53:06 -0500 Subject: [PATCH] Move api/errdefs to errdefs Signed-off-by: Brian Goff Upstream-commit: d453fe35b9b8b52d0677fe0c3cc8373f2f5d30d0 Component: engine --- components/engine/api/server/httputils/errors.go | 2 +- components/engine/api/server/httputils/httputils.go | 2 +- components/engine/api/server/router/build/build_routes.go | 2 +- .../engine/api/server/router/container/container_routes.go | 2 +- components/engine/api/server/router/container/exec.go | 2 +- components/engine/api/server/router/image/image_routes.go | 2 +- components/engine/api/server/router/network/network_routes.go | 2 +- components/engine/api/server/router/session/session_routes.go | 2 +- components/engine/api/server/router/swarm/cluster_routes.go | 2 +- components/engine/builder/dockerfile/builder.go | 2 +- components/engine/builder/dockerfile/dispatchers.go | 2 +- components/engine/builder/dockerfile/evaluator.go | 2 +- components/engine/builder/remotecontext/remote.go | 2 +- components/engine/daemon/archive.go | 2 +- components/engine/daemon/attach.go | 2 +- .../engine/daemon/cluster/controllers/plugin/controller.go | 2 +- components/engine/daemon/cluster/helpers.go | 2 +- components/engine/daemon/cluster/networks.go | 2 +- components/engine/daemon/cluster/nodes.go | 2 +- components/engine/daemon/cluster/services.go | 2 +- components/engine/daemon/cluster/swarm.go | 2 +- components/engine/daemon/commit.go | 2 +- components/engine/daemon/container.go | 2 +- components/engine/daemon/container_linux.go | 2 +- components/engine/daemon/container_operations.go | 2 +- components/engine/daemon/container_operations_unix.go | 2 +- components/engine/daemon/create.go | 2 +- components/engine/daemon/daemon.go | 2 +- components/engine/daemon/daemon_test.go | 2 +- components/engine/daemon/delete.go | 2 +- components/engine/daemon/errors.go | 2 +- components/engine/daemon/exec.go | 2 +- components/engine/daemon/export.go | 2 +- components/engine/daemon/graphdriver/quota/errors.go | 2 +- components/engine/daemon/image.go | 2 +- components/engine/daemon/image_delete.go | 2 +- components/engine/daemon/image_pull.go | 2 +- components/engine/daemon/import.go | 2 +- components/engine/daemon/inspect.go | 2 +- components/engine/daemon/kill.go | 2 +- components/engine/daemon/list.go | 2 +- components/engine/daemon/logs.go | 2 +- components/engine/daemon/names.go | 2 +- components/engine/daemon/network.go | 2 +- components/engine/daemon/rename.go | 2 +- components/engine/daemon/start.go | 2 +- components/engine/daemon/start_unix.go | 2 +- components/engine/daemon/stop.go | 2 +- components/engine/daemon/update.go | 2 +- components/engine/daemon/volumes.go | 2 +- components/engine/distribution/errors.go | 2 +- components/engine/{api => }/errdefs/defs.go | 0 components/engine/{api => }/errdefs/doc.go | 0 components/engine/{api => }/errdefs/helpers.go | 0 components/engine/{api => }/errdefs/helpers_test.go | 0 components/engine/{api => }/errdefs/is.go | 0 components/engine/libcontainerd/client_daemon.go | 2 +- components/engine/libcontainerd/errors.go | 2 +- components/engine/plugin/backend_linux.go | 2 +- components/engine/plugin/executor/containerd/containerd.go | 2 +- components/engine/plugin/manager_linux.go | 2 +- components/engine/plugin/store.go | 2 +- components/engine/registry/auth.go | 2 +- components/engine/registry/errors.go | 2 +- components/engine/registry/service.go | 2 +- components/engine/registry/session.go | 2 +- components/engine/volume/local/local.go | 2 +- 67 files changed, 62 insertions(+), 62 deletions(-) rename components/engine/{api => }/errdefs/defs.go (100%) rename components/engine/{api => }/errdefs/doc.go (100%) rename components/engine/{api => }/errdefs/helpers.go (100%) rename components/engine/{api => }/errdefs/helpers_test.go (100%) rename components/engine/{api => }/errdefs/is.go (100%) diff --git a/components/engine/api/server/httputils/errors.go b/components/engine/api/server/httputils/errors.go index 577d19c166..f5008223c9 100644 --- a/components/engine/api/server/httputils/errors.go +++ b/components/engine/api/server/httputils/errors.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/gorilla/mux" "github.com/sirupsen/logrus" "google.golang.org/grpc" diff --git a/components/engine/api/server/httputils/httputils.go b/components/engine/api/server/httputils/httputils.go index dbf5b7a2a0..e292928bf6 100644 --- a/components/engine/api/server/httputils/httputils.go +++ b/components/engine/api/server/httputils/httputils.go @@ -6,7 +6,7 @@ import ( "net/http" "strings" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" "golang.org/x/net/context" diff --git a/components/engine/api/server/router/build/build_routes.go b/components/engine/api/server/router/build/build_routes.go index 553f8fcee4..491fa85a86 100644 --- a/components/engine/api/server/router/build/build_routes.go +++ b/components/engine/api/server/router/build/build_routes.go @@ -13,12 +13,12 @@ import ( "strings" "sync" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/docker/docker/pkg/progress" "github.com/docker/docker/pkg/streamformatter" diff --git a/components/engine/api/server/router/container/container_routes.go b/components/engine/api/server/router/container/container_routes.go index 0343072283..5f8456d706 100644 --- a/components/engine/api/server/router/container/container_routes.go +++ b/components/engine/api/server/router/container/container_routes.go @@ -8,7 +8,6 @@ import ( "strconv" "syscall" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" @@ -16,6 +15,7 @@ import ( "github.com/docker/docker/api/types/filters" "github.com/docker/docker/api/types/versions" containerpkg "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/docker/docker/pkg/signal" "github.com/pkg/errors" diff --git a/components/engine/api/server/router/container/exec.go b/components/engine/api/server/router/container/exec.go index 60be8476eb..6dfca729c5 100644 --- a/components/engine/api/server/router/container/exec.go +++ b/components/engine/api/server/router/container/exec.go @@ -7,10 +7,10 @@ import ( "net/http" "strconv" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/stdcopy" "github.com/sirupsen/logrus" "golang.org/x/net/context" diff --git a/components/engine/api/server/router/image/image_routes.go b/components/engine/api/server/router/image/image_routes.go index 42e2710828..dc16a23af0 100644 --- a/components/engine/api/server/router/image/image_routes.go +++ b/components/engine/api/server/router/image/image_routes.go @@ -10,12 +10,12 @@ import ( "strconv" "strings" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/docker/docker/pkg/streamformatter" "github.com/docker/docker/pkg/system" diff --git a/components/engine/api/server/router/network/network_routes.go b/components/engine/api/server/router/network/network_routes.go index eb5dfe2a4d..fcfeb83f55 100644 --- a/components/engine/api/server/router/network/network_routes.go +++ b/components/engine/api/server/router/network/network_routes.go @@ -8,12 +8,12 @@ import ( "golang.org/x/net/context" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/api/types/network" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/docker/libnetwork" netconst "github.com/docker/libnetwork/datastore" "github.com/docker/libnetwork/networkdb" diff --git a/components/engine/api/server/router/session/session_routes.go b/components/engine/api/server/router/session/session_routes.go index 49493cdf64..8eb8074ebc 100644 --- a/components/engine/api/server/router/session/session_routes.go +++ b/components/engine/api/server/router/session/session_routes.go @@ -3,7 +3,7 @@ package session import ( "net/http" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "golang.org/x/net/context" ) diff --git a/components/engine/api/server/router/swarm/cluster_routes.go b/components/engine/api/server/router/swarm/cluster_routes.go index 124900d459..bd98acfcf1 100644 --- a/components/engine/api/server/router/swarm/cluster_routes.go +++ b/components/engine/api/server/router/swarm/cluster_routes.go @@ -6,13 +6,13 @@ import ( "net/http" "strconv" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/server/httputils" basictypes "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" "github.com/docker/docker/api/types/filters" types "github.com/docker/docker/api/types/swarm" "github.com/docker/docker/api/types/versions" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" "golang.org/x/net/context" diff --git a/components/engine/builder/dockerfile/builder.go b/components/engine/builder/dockerfile/builder.go index bd2418f59e..0354b2d3f9 100644 --- a/components/engine/builder/dockerfile/builder.go +++ b/components/engine/builder/dockerfile/builder.go @@ -9,7 +9,6 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" "github.com/docker/docker/api/types/container" @@ -18,6 +17,7 @@ import ( "github.com/docker/docker/builder/dockerfile/parser" "github.com/docker/docker/builder/fscache" "github.com/docker/docker/builder/remotecontext" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/idtools" "github.com/docker/docker/pkg/streamformatter" "github.com/docker/docker/pkg/stringid" diff --git a/components/engine/builder/dockerfile/dispatchers.go b/components/engine/builder/dockerfile/dispatchers.go index f1f886007e..1cf275d8c4 100644 --- a/components/engine/builder/dockerfile/dispatchers.go +++ b/components/engine/builder/dockerfile/dispatchers.go @@ -15,12 +15,12 @@ import ( "strings" "github.com/docker/docker/api" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/strslice" "github.com/docker/docker/builder" "github.com/docker/docker/builder/dockerfile/instructions" "github.com/docker/docker/builder/dockerfile/parser" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/pkg/jsonmessage" "github.com/docker/docker/pkg/signal" diff --git a/components/engine/builder/dockerfile/evaluator.go b/components/engine/builder/dockerfile/evaluator.go index de9cdaa924..cf3d4fd01e 100644 --- a/components/engine/builder/dockerfile/evaluator.go +++ b/components/engine/builder/dockerfile/evaluator.go @@ -24,10 +24,10 @@ import ( "strconv" "strings" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/container" "github.com/docker/docker/builder" "github.com/docker/docker/builder/dockerfile/instructions" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/system" "github.com/docker/docker/runconfig/opts" "github.com/pkg/errors" diff --git a/components/engine/builder/remotecontext/remote.go b/components/engine/builder/remotecontext/remote.go index 0c3345c785..b67914cc11 100644 --- a/components/engine/builder/remotecontext/remote.go +++ b/components/engine/builder/remotecontext/remote.go @@ -10,7 +10,7 @@ import ( "net/url" "regexp" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/pkg/errors" ) diff --git a/components/engine/daemon/archive.go b/components/engine/daemon/archive.go index ddc4b572bd..69301342ef 100644 --- a/components/engine/daemon/archive.go +++ b/components/engine/daemon/archive.go @@ -5,9 +5,9 @@ import ( "os" "strings" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/archive" "github.com/docker/docker/pkg/chrootarchive" "github.com/docker/docker/pkg/ioutils" diff --git a/components/engine/daemon/attach.go b/components/engine/daemon/attach.go index 1b52fd0168..d63eaa6632 100644 --- a/components/engine/daemon/attach.go +++ b/components/engine/daemon/attach.go @@ -5,11 +5,11 @@ import ( "fmt" "io" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/backend" "github.com/docker/docker/container" "github.com/docker/docker/container/stream" "github.com/docker/docker/daemon/logger" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/stdcopy" "github.com/docker/docker/pkg/term" "github.com/pkg/errors" diff --git a/components/engine/daemon/cluster/controllers/plugin/controller.go b/components/engine/daemon/cluster/controllers/plugin/controller.go index b48c9fd4e2..d4f24e82df 100644 --- a/components/engine/daemon/cluster/controllers/plugin/controller.go +++ b/components/engine/daemon/cluster/controllers/plugin/controller.go @@ -6,9 +6,9 @@ import ( "net/http" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" enginetypes "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/swarm/runtime" + "github.com/docker/docker/errdefs" "github.com/docker/docker/plugin" "github.com/docker/docker/plugin/v2" "github.com/docker/swarmkit/api" diff --git a/components/engine/daemon/cluster/helpers.go b/components/engine/daemon/cluster/helpers.go index 52d0cd173d..9541bff390 100644 --- a/components/engine/daemon/cluster/helpers.go +++ b/components/engine/daemon/cluster/helpers.go @@ -3,7 +3,7 @@ package cluster import ( "fmt" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" swarmapi "github.com/docker/swarmkit/api" "github.com/pkg/errors" "golang.org/x/net/context" diff --git a/components/engine/daemon/cluster/networks.go b/components/engine/daemon/cluster/networks.go index e43808ddba..081526f768 100644 --- a/components/engine/daemon/cluster/networks.go +++ b/components/engine/daemon/cluster/networks.go @@ -3,11 +3,11 @@ package cluster import ( "fmt" - "github.com/docker/docker/api/errdefs" apitypes "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/network" types "github.com/docker/docker/api/types/swarm" "github.com/docker/docker/daemon/cluster/convert" + "github.com/docker/docker/errdefs" "github.com/docker/docker/runconfig" swarmapi "github.com/docker/swarmkit/api" "github.com/pkg/errors" diff --git a/components/engine/daemon/cluster/nodes.go b/components/engine/daemon/cluster/nodes.go index 6a345bea0a..879d272e75 100644 --- a/components/engine/daemon/cluster/nodes.go +++ b/components/engine/daemon/cluster/nodes.go @@ -1,10 +1,10 @@ package cluster import ( - "github.com/docker/docker/api/errdefs" apitypes "github.com/docker/docker/api/types" types "github.com/docker/docker/api/types/swarm" "github.com/docker/docker/daemon/cluster/convert" + "github.com/docker/docker/errdefs" swarmapi "github.com/docker/swarmkit/api" "golang.org/x/net/context" ) diff --git a/components/engine/daemon/cluster/services.go b/components/engine/daemon/cluster/services.go index 6d2676540e..931d17c75f 100644 --- a/components/engine/daemon/cluster/services.go +++ b/components/engine/daemon/cluster/services.go @@ -11,12 +11,12 @@ import ( "time" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" apitypes "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" types "github.com/docker/docker/api/types/swarm" timetypes "github.com/docker/docker/api/types/time" "github.com/docker/docker/daemon/cluster/convert" + "github.com/docker/docker/errdefs" runconfigopts "github.com/docker/docker/runconfig/opts" swarmapi "github.com/docker/swarmkit/api" gogotypes "github.com/gogo/protobuf/types" diff --git a/components/engine/daemon/cluster/swarm.go b/components/engine/daemon/cluster/swarm.go index 4de44656d9..3c7a23b71d 100644 --- a/components/engine/daemon/cluster/swarm.go +++ b/components/engine/daemon/cluster/swarm.go @@ -6,11 +6,11 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" apitypes "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/filters" types "github.com/docker/docker/api/types/swarm" "github.com/docker/docker/daemon/cluster/convert" + "github.com/docker/docker/errdefs" "github.com/docker/docker/opts" "github.com/docker/docker/pkg/signal" swarmapi "github.com/docker/swarmkit/api" diff --git a/components/engine/daemon/commit.go b/components/engine/daemon/commit.go index 3208b17817..b2c969316b 100644 --- a/components/engine/daemon/commit.go +++ b/components/engine/daemon/commit.go @@ -9,11 +9,11 @@ import ( "time" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/backend" containertypes "github.com/docker/docker/api/types/container" "github.com/docker/docker/builder/dockerfile" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/layer" "github.com/docker/docker/pkg/ioutils" diff --git a/components/engine/daemon/container.go b/components/engine/daemon/container.go index c062e7ac76..d55c98f5a7 100644 --- a/components/engine/daemon/container.go +++ b/components/engine/daemon/container.go @@ -9,11 +9,11 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" containertypes "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/strslice" "github.com/docker/docker/container" "github.com/docker/docker/daemon/network" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/opts" "github.com/docker/docker/pkg/signal" diff --git a/components/engine/daemon/container_linux.go b/components/engine/daemon/container_linux.go index 6c9d52509f..d63f4b72a5 100644 --- a/components/engine/daemon/container_linux.go +++ b/components/engine/daemon/container_linux.go @@ -3,8 +3,8 @@ package daemon import ( - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" ) func (daemon *Daemon) saveApparmorConfig(container *container.Container) error { diff --git a/components/engine/daemon/container_operations.go b/components/engine/daemon/container_operations.go index aa18f3767c..32846a2f77 100644 --- a/components/engine/daemon/container_operations.go +++ b/components/engine/daemon/container_operations.go @@ -10,11 +10,11 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" containertypes "github.com/docker/docker/api/types/container" networktypes "github.com/docker/docker/api/types/network" "github.com/docker/docker/container" "github.com/docker/docker/daemon/network" + "github.com/docker/docker/errdefs" "github.com/docker/docker/opts" "github.com/docker/docker/pkg/stringid" "github.com/docker/docker/runconfig" diff --git a/components/engine/daemon/container_operations_unix.go b/components/engine/daemon/container_operations_unix.go index 9eff1ebfbc..9fe899b623 100644 --- a/components/engine/daemon/container_operations_unix.go +++ b/components/engine/daemon/container_operations_unix.go @@ -11,9 +11,9 @@ import ( "strconv" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/container" "github.com/docker/docker/daemon/links" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/idtools" "github.com/docker/docker/pkg/mount" "github.com/docker/docker/pkg/stringid" diff --git a/components/engine/daemon/create.go b/components/engine/daemon/create.go index a9c9e775ad..54ce12c239 100644 --- a/components/engine/daemon/create.go +++ b/components/engine/daemon/create.go @@ -9,11 +9,11 @@ import ( "github.com/pkg/errors" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" containertypes "github.com/docker/docker/api/types/container" networktypes "github.com/docker/docker/api/types/network" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/layer" "github.com/docker/docker/pkg/idtools" diff --git a/components/engine/daemon/daemon.go b/components/engine/daemon/daemon.go index dd8c100c83..0f05f5783a 100644 --- a/components/engine/daemon/daemon.go +++ b/components/engine/daemon/daemon.go @@ -18,7 +18,6 @@ import ( "sync" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" containertypes "github.com/docker/docker/api/types/container" "github.com/docker/docker/api/types/swarm" @@ -29,6 +28,7 @@ import ( "github.com/docker/docker/daemon/exec" "github.com/docker/docker/daemon/logger" "github.com/docker/docker/daemon/network" + "github.com/docker/docker/errdefs" "github.com/sirupsen/logrus" // register graph drivers _ "github.com/docker/docker/daemon/graphdriver/register" diff --git a/components/engine/daemon/daemon_test.go b/components/engine/daemon/daemon_test.go index 44bf3414c0..8ca1f0dd57 100644 --- a/components/engine/daemon/daemon_test.go +++ b/components/engine/daemon/daemon_test.go @@ -7,9 +7,9 @@ import ( "runtime" "testing" - "github.com/docker/docker/api/errdefs" containertypes "github.com/docker/docker/api/types/container" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" _ "github.com/docker/docker/pkg/discovery/memory" "github.com/docker/docker/pkg/idtools" "github.com/docker/docker/pkg/truncindex" diff --git a/components/engine/daemon/delete.go b/components/engine/daemon/delete.go index e6fc1a5264..5fb9b9a1d9 100644 --- a/components/engine/daemon/delete.go +++ b/components/engine/daemon/delete.go @@ -7,9 +7,9 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/layer" "github.com/docker/docker/pkg/system" "github.com/docker/docker/volume" diff --git a/components/engine/daemon/errors.go b/components/engine/daemon/errors.go index b39f9d1720..e3a16b0586 100644 --- a/components/engine/daemon/errors.go +++ b/components/engine/daemon/errors.go @@ -5,7 +5,7 @@ import ( "strings" "syscall" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "google.golang.org/grpc" ) diff --git a/components/engine/daemon/exec.go b/components/engine/daemon/exec.go index 9955053739..6fe107987a 100644 --- a/components/engine/daemon/exec.go +++ b/components/engine/daemon/exec.go @@ -8,12 +8,12 @@ import ( "golang.org/x/net/context" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/strslice" "github.com/docker/docker/container" "github.com/docker/docker/container/stream" "github.com/docker/docker/daemon/exec" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/pools" "github.com/docker/docker/pkg/signal" "github.com/docker/docker/pkg/term" diff --git a/components/engine/daemon/export.go b/components/engine/daemon/export.go index 6024f74259..66a0cca048 100644 --- a/components/engine/daemon/export.go +++ b/components/engine/daemon/export.go @@ -5,8 +5,8 @@ import ( "io" "runtime" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/archive" "github.com/docker/docker/pkg/ioutils" ) diff --git a/components/engine/daemon/graphdriver/quota/errors.go b/components/engine/daemon/graphdriver/quota/errors.go index 1741f2f5db..6d755904a8 100644 --- a/components/engine/daemon/graphdriver/quota/errors.go +++ b/components/engine/daemon/graphdriver/quota/errors.go @@ -1,6 +1,6 @@ package quota -import "github.com/docker/docker/api/errdefs" +import "github.com/docker/docker/errdefs" var ( _ errdefs.ErrNotImplemented = (*errQuotaNotSupported)(nil) diff --git a/components/engine/daemon/image.go b/components/engine/daemon/image.go index a59f0ff205..fdbd6e2be7 100644 --- a/components/engine/daemon/image.go +++ b/components/engine/daemon/image.go @@ -5,7 +5,7 @@ import ( "runtime" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" ) diff --git a/components/engine/daemon/image_delete.go b/components/engine/daemon/image_delete.go index a4b1299909..36ac2c7c68 100644 --- a/components/engine/daemon/image_delete.go +++ b/components/engine/daemon/image_delete.go @@ -6,9 +6,9 @@ import ( "time" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/pkg/stringid" "github.com/pkg/errors" diff --git a/components/engine/daemon/image_pull.go b/components/engine/daemon/image_pull.go index b59753ac00..4944721f9f 100644 --- a/components/engine/daemon/image_pull.go +++ b/components/engine/daemon/image_pull.go @@ -7,10 +7,10 @@ import ( dist "github.com/docker/distribution" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/distribution" progressutils "github.com/docker/docker/distribution/utils" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/progress" "github.com/docker/docker/registry" "github.com/opencontainers/go-digest" diff --git a/components/engine/daemon/import.go b/components/engine/daemon/import.go index b41f8e579e..3ac83a9fa9 100644 --- a/components/engine/daemon/import.go +++ b/components/engine/daemon/import.go @@ -10,11 +10,11 @@ import ( "time" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/container" "github.com/docker/docker/builder/dockerfile" "github.com/docker/docker/builder/remotecontext" "github.com/docker/docker/dockerversion" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/layer" "github.com/docker/docker/pkg/archive" diff --git a/components/engine/daemon/inspect.go b/components/engine/daemon/inspect.go index 25805b296e..cab4f9279c 100644 --- a/components/engine/daemon/inspect.go +++ b/components/engine/daemon/inspect.go @@ -4,7 +4,6 @@ import ( "fmt" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" networktypes "github.com/docker/docker/api/types/network" @@ -12,6 +11,7 @@ import ( "github.com/docker/docker/api/types/versions/v1p20" "github.com/docker/docker/container" "github.com/docker/docker/daemon/network" + "github.com/docker/docker/errdefs" volumestore "github.com/docker/docker/volume/store" "github.com/docker/go-connections/nat" ) diff --git a/components/engine/daemon/kill.go b/components/engine/daemon/kill.go index 5cde0d776d..ad6104bfe9 100644 --- a/components/engine/daemon/kill.go +++ b/components/engine/daemon/kill.go @@ -7,8 +7,8 @@ import ( "syscall" "time" - "github.com/docker/docker/api/errdefs" containerpkg "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/libcontainerd" "github.com/docker/docker/pkg/signal" "github.com/pkg/errors" diff --git a/components/engine/daemon/list.go b/components/engine/daemon/list.go index 73d3f56769..8598d25280 100644 --- a/components/engine/daemon/list.go +++ b/components/engine/daemon/list.go @@ -6,10 +6,10 @@ import ( "strconv" "strings" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/volume" "github.com/docker/go-connections/nat" diff --git a/components/engine/daemon/logs.go b/components/engine/daemon/logs.go index 612aeecb14..c819768dc3 100644 --- a/components/engine/daemon/logs.go +++ b/components/engine/daemon/logs.go @@ -7,13 +7,13 @@ import ( "golang.org/x/net/context" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/backend" containertypes "github.com/docker/docker/api/types/container" timetypes "github.com/docker/docker/api/types/time" "github.com/docker/docker/container" "github.com/docker/docker/daemon/logger" + "github.com/docker/docker/errdefs" "github.com/sirupsen/logrus" ) diff --git a/components/engine/daemon/names.go b/components/engine/daemon/names.go index da87447676..0e43738849 100644 --- a/components/engine/daemon/names.go +++ b/components/engine/daemon/names.go @@ -4,9 +4,9 @@ import ( "fmt" "strings" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/container" "github.com/docker/docker/daemon/names" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/namesgenerator" "github.com/docker/docker/pkg/stringid" "github.com/pkg/errors" diff --git a/components/engine/daemon/network.go b/components/engine/daemon/network.go index 3deb13ef88..35db27148a 100644 --- a/components/engine/daemon/network.go +++ b/components/engine/daemon/network.go @@ -8,10 +8,10 @@ import ( "strings" "sync" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/network" clustertypes "github.com/docker/docker/daemon/cluster/provider" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/plugingetter" "github.com/docker/docker/runconfig" "github.com/docker/libnetwork" diff --git a/components/engine/daemon/rename.go b/components/engine/daemon/rename.go index 14e66be1b5..fd13d898e2 100644 --- a/components/engine/daemon/rename.go +++ b/components/engine/daemon/rename.go @@ -3,8 +3,8 @@ package daemon import ( "strings" - "github.com/docker/docker/api/errdefs" dockercontainer "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/libnetwork" "github.com/pkg/errors" "github.com/sirupsen/logrus" diff --git a/components/engine/daemon/start.go b/components/engine/daemon/start.go index 9509089f0f..aa080f7174 100644 --- a/components/engine/daemon/start.go +++ b/components/engine/daemon/start.go @@ -5,10 +5,10 @@ import ( "runtime" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" containertypes "github.com/docker/docker/api/types/container" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" ) diff --git a/components/engine/daemon/start_unix.go b/components/engine/daemon/start_unix.go index 1efd07f959..ca0183ec5c 100644 --- a/components/engine/daemon/start_unix.go +++ b/components/engine/daemon/start_unix.go @@ -8,8 +8,8 @@ import ( "path/filepath" "github.com/containerd/containerd/linux/runctypes" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" ) diff --git a/components/engine/daemon/stop.go b/components/engine/daemon/stop.go index 9b0bdcd2e3..d3b5297fb2 100644 --- a/components/engine/daemon/stop.go +++ b/components/engine/daemon/stop.go @@ -4,8 +4,8 @@ import ( "context" "time" - "github.com/docker/docker/api/errdefs" containerpkg "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" ) diff --git a/components/engine/daemon/update.go b/components/engine/daemon/update.go index 49321934be..d2eb33a75e 100644 --- a/components/engine/daemon/update.go +++ b/components/engine/daemon/update.go @@ -4,8 +4,8 @@ import ( "context" "fmt" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types/container" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" ) diff --git a/components/engine/daemon/volumes.go b/components/engine/daemon/volumes.go index 2e667c873d..2e75feebda 100644 --- a/components/engine/daemon/volumes.go +++ b/components/engine/daemon/volumes.go @@ -8,11 +8,11 @@ import ( "strings" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" containertypes "github.com/docker/docker/api/types/container" mounttypes "github.com/docker/docker/api/types/mount" "github.com/docker/docker/container" + "github.com/docker/docker/errdefs" "github.com/docker/docker/volume" "github.com/docker/docker/volume/drivers" "github.com/pkg/errors" diff --git a/components/engine/distribution/errors.go b/components/engine/distribution/errors.go index 3edeb3717f..49e8e5c0c1 100644 --- a/components/engine/distribution/errors.go +++ b/components/engine/distribution/errors.go @@ -12,8 +12,8 @@ import ( "github.com/docker/distribution/registry/api/v2" "github.com/docker/distribution/registry/client" "github.com/docker/distribution/registry/client/auth" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/distribution/xfer" + "github.com/docker/docker/errdefs" "github.com/sirupsen/logrus" ) diff --git a/components/engine/api/errdefs/defs.go b/components/engine/errdefs/defs.go similarity index 100% rename from components/engine/api/errdefs/defs.go rename to components/engine/errdefs/defs.go diff --git a/components/engine/api/errdefs/doc.go b/components/engine/errdefs/doc.go similarity index 100% rename from components/engine/api/errdefs/doc.go rename to components/engine/errdefs/doc.go diff --git a/components/engine/api/errdefs/helpers.go b/components/engine/errdefs/helpers.go similarity index 100% rename from components/engine/api/errdefs/helpers.go rename to components/engine/errdefs/helpers.go diff --git a/components/engine/api/errdefs/helpers_test.go b/components/engine/errdefs/helpers_test.go similarity index 100% rename from components/engine/api/errdefs/helpers_test.go rename to components/engine/errdefs/helpers_test.go diff --git a/components/engine/api/errdefs/is.go b/components/engine/errdefs/is.go similarity index 100% rename from components/engine/api/errdefs/is.go rename to components/engine/errdefs/is.go diff --git a/components/engine/libcontainerd/client_daemon.go b/components/engine/libcontainerd/client_daemon.go index cc0c099c43..9e66d224c6 100644 --- a/components/engine/libcontainerd/client_daemon.go +++ b/components/engine/libcontainerd/client_daemon.go @@ -31,7 +31,7 @@ import ( "github.com/containerd/containerd/images" "github.com/containerd/containerd/linux/runctypes" "github.com/containerd/typeurl" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/opencontainers/image-spec/specs-go/v1" specs "github.com/opencontainers/runtime-spec/specs-go" diff --git a/components/engine/libcontainerd/errors.go b/components/engine/libcontainerd/errors.go index 1ecec7ba9d..dcd2525312 100644 --- a/components/engine/libcontainerd/errors.go +++ b/components/engine/libcontainerd/errors.go @@ -3,7 +3,7 @@ package libcontainerd import ( "errors" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" ) func newNotFoundError(err string) error { return errdefs.NotFound(errors.New(err)) } diff --git a/components/engine/plugin/backend_linux.go b/components/engine/plugin/backend_linux.go index 3437a7dca2..46bdfdbb1f 100644 --- a/components/engine/plugin/backend_linux.go +++ b/components/engine/plugin/backend_linux.go @@ -14,13 +14,13 @@ import ( "github.com/docker/distribution/manifest/schema2" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/api/types/filters" "github.com/docker/docker/distribution" progressutils "github.com/docker/docker/distribution/utils" "github.com/docker/docker/distribution/xfer" "github.com/docker/docker/dockerversion" + "github.com/docker/docker/errdefs" "github.com/docker/docker/image" "github.com/docker/docker/layer" "github.com/docker/docker/pkg/authorization" diff --git a/components/engine/plugin/executor/containerd/containerd.go b/components/engine/plugin/executor/containerd/containerd.go index 38dcfcd58c..7b35136a1f 100644 --- a/components/engine/plugin/executor/containerd/containerd.go +++ b/components/engine/plugin/executor/containerd/containerd.go @@ -8,7 +8,7 @@ import ( "github.com/containerd/containerd/cio" "github.com/containerd/containerd/linux/runctypes" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/docker/docker/libcontainerd" "github.com/opencontainers/runtime-spec/specs-go" "github.com/pkg/errors" diff --git a/components/engine/plugin/manager_linux.go b/components/engine/plugin/manager_linux.go index 888f06dd91..65380af06f 100644 --- a/components/engine/plugin/manager_linux.go +++ b/components/engine/plugin/manager_linux.go @@ -7,9 +7,9 @@ import ( "path/filepath" "time" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" "github.com/docker/docker/daemon/initlayer" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/containerfs" "github.com/docker/docker/pkg/idtools" "github.com/docker/docker/pkg/mount" diff --git a/components/engine/plugin/store.go b/components/engine/plugin/store.go index 4ce817491c..9768c25068 100644 --- a/components/engine/plugin/store.go +++ b/components/engine/plugin/store.go @@ -5,7 +5,7 @@ import ( "strings" "github.com/docker/distribution/reference" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/plugingetter" "github.com/docker/docker/pkg/plugins" "github.com/docker/docker/plugin/v2" diff --git a/components/engine/registry/auth.go b/components/engine/registry/auth.go index e91631701d..56b9c88295 100644 --- a/components/engine/registry/auth.go +++ b/components/engine/registry/auth.go @@ -10,9 +10,9 @@ import ( "github.com/docker/distribution/registry/client/auth" "github.com/docker/distribution/registry/client/auth/challenge" "github.com/docker/distribution/registry/client/transport" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" registrytypes "github.com/docker/docker/api/types/registry" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" ) diff --git a/components/engine/registry/errors.go b/components/engine/registry/errors.go index 1b8ea97f36..55f74d97ed 100644 --- a/components/engine/registry/errors.go +++ b/components/engine/registry/errors.go @@ -4,7 +4,7 @@ import ( "net/url" "github.com/docker/distribution/registry/api/errcode" - "github.com/docker/docker/api/errdefs" + "github.com/docker/docker/errdefs" ) type notFoundError string diff --git a/components/engine/registry/service.go b/components/engine/registry/service.go index ac240f0c69..bf4ab94d9f 100644 --- a/components/engine/registry/service.go +++ b/components/engine/registry/service.go @@ -11,9 +11,9 @@ import ( "github.com/docker/distribution/reference" "github.com/docker/distribution/registry/client/auth" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" registrytypes "github.com/docker/docker/api/types/registry" + "github.com/docker/docker/errdefs" "github.com/pkg/errors" "github.com/sirupsen/logrus" ) diff --git a/components/engine/registry/session.go b/components/engine/registry/session.go index 89c374f618..ae0ec1b4bf 100644 --- a/components/engine/registry/session.go +++ b/components/engine/registry/session.go @@ -19,9 +19,9 @@ import ( "github.com/docker/distribution/reference" "github.com/docker/distribution/registry/api/errcode" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/api/types" registrytypes "github.com/docker/docker/api/types/registry" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/ioutils" "github.com/docker/docker/pkg/jsonmessage" "github.com/docker/docker/pkg/stringid" diff --git a/components/engine/volume/local/local.go b/components/engine/volume/local/local.go index 49e18b761a..206d96506c 100644 --- a/components/engine/volume/local/local.go +++ b/components/engine/volume/local/local.go @@ -13,8 +13,8 @@ import ( "strings" "sync" - "github.com/docker/docker/api/errdefs" "github.com/docker/docker/daemon/names" + "github.com/docker/docker/errdefs" "github.com/docker/docker/pkg/idtools" "github.com/docker/docker/pkg/mount" "github.com/docker/docker/volume"