builder: fix private pulls on buildkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com> (cherry picked from commit c693d45acf74b87680ace0db8615f97bd6853598) Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com> Upstream-commit: fdaf08a57b2348623f33e0b9855c488421fc7bf6 Component: engine
This commit is contained in:
@@ -75,12 +75,12 @@ func (is *imageSource) ID() string {
|
||||
|
||||
func (is *imageSource) getResolver(ctx context.Context, rfn resolver.ResolveOptionsFunc, ref string) remotes.Resolver {
|
||||
opt := docker.ResolverOptions{
|
||||
Client: tracing.DefaultClient,
|
||||
Credentials: is.getCredentialsFromSession(ctx),
|
||||
Client: tracing.DefaultClient,
|
||||
}
|
||||
if rfn != nil {
|
||||
opt = rfn(ref)
|
||||
}
|
||||
opt.Credentials = is.getCredentialsFromSession(ctx)
|
||||
r := docker.NewResolver(opt)
|
||||
return r
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user