Extract squash and tagging from the Dockerfile builder.

Remove pathCache and replace it with syncmap
Cleanup NewBuilder
Create an api/server/backend/build
Extract BuildTagger

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 0296797f0f39477d675128c93c1646b3186937ee
Component: engine
This commit is contained in:
Daniel Nephin
2017-05-01 12:07:32 -04:00
parent dff17659b7
commit 3d193f829d
15 changed files with 337 additions and 259 deletions
+2 -2
View File
@@ -14,6 +14,7 @@ import (
"github.com/docker/distribution/uuid"
"github.com/docker/docker/api"
apiserver "github.com/docker/docker/api/server"
buildbackend "github.com/docker/docker/api/server/backend/build"
"github.com/docker/docker/api/server/middleware"
"github.com/docker/docker/api/server/router"
"github.com/docker/docker/api/server/router/build"
@@ -25,7 +26,6 @@ import (
swarmrouter "github.com/docker/docker/api/server/router/swarm"
systemrouter "github.com/docker/docker/api/server/router/system"
"github.com/docker/docker/api/server/router/volume"
"github.com/docker/docker/builder/dockerfile"
cliconfig "github.com/docker/docker/cli/config"
"github.com/docker/docker/cli/debug"
cliflags "github.com/docker/docker/cli/flags"
@@ -484,7 +484,7 @@ func initRouter(s *apiserver.Server, d *daemon.Daemon, c *cluster.Cluster) {
image.NewRouter(d, decoder),
systemrouter.NewRouter(d, c),
volume.NewRouter(d),
build.NewRouter(dockerfile.NewBuildManager(d)),
build.NewRouter(buildbackend.NewBackend(d, d), d),
swarmrouter.NewRouter(c),
pluginrouter.NewRouter(d.PluginManager()),
}