mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #37597 from tiborvass/fix-cancel-bug
builder: do not cancel buildkit status request
This commit is contained in:
commit
080c27dd13
1 changed files with 4 additions and 3 deletions
|
@ -258,9 +258,10 @@ func (b *Builder) Build(ctx context.Context, opt backend.BuildConfig) (*builder.
|
||||||
|
|
||||||
eg.Go(func() error {
|
eg.Go(func() error {
|
||||||
defer close(ch)
|
defer close(ch)
|
||||||
return b.controller.Status(&controlapi.StatusRequest{
|
// streamProxy.ctx is not set to ctx because when request is cancelled,
|
||||||
Ref: id,
|
// only the build request has to be cancelled, not the status request.
|
||||||
}, &statusProxy{streamProxy: streamProxy{ctx: ctx}, ch: ch})
|
stream := &statusProxy{streamProxy: streamProxy{ctx: context.TODO()}, ch: ch}
|
||||||
|
return b.controller.Status(&controlapi.StatusRequest{Ref: id}, stream)
|
||||||
})
|
})
|
||||||
|
|
||||||
eg.Go(func() error {
|
eg.Go(func() error {
|
||||||
|
|
Loading…
Add table
Reference in a new issue