Remove unused Builder.Cancel()

Signed-off-by: Daniel Nephin <dnephin@docker.com>
This commit is contained in:
Daniel Nephin 2017-04-11 14:06:51 -04:00
parent a6abd57b83
commit 068f344e03
1 changed files with 1 additions and 9 deletions

View File

@ -50,7 +50,6 @@ type Builder struct {
docker builder.Backend
context builder.Context
clientCtx context.Context
cancel context.CancelFunc
runConfig *container.Config // runconfig for cmd, run, entrypoint etc.
flags *BFlags
@ -113,10 +112,8 @@ func NewBuilder(clientCtx context.Context, config *types.ImageBuildOptions, back
if config == nil {
config = new(types.ImageBuildOptions)
}
ctx, cancel := context.WithCancel(clientCtx)
b = &Builder{
clientCtx: ctx,
cancel: cancel,
clientCtx: clientCtx,
options: config,
Stdout: os.Stdout,
Stderr: os.Stderr,
@ -313,11 +310,6 @@ func (b *Builder) hasFromImage() bool {
return b.image != "" || b.noBaseImage
}
// Cancel cancels an ongoing Dockerfile build.
func (b *Builder) Cancel() {
b.cancel()
}
// BuildFromConfig builds directly from `changes`, treating it as if it were the contents of a Dockerfile
// It will:
// - Call parse.Parse() to get an AST root for the concatenated Dockerfile entries.