-
Notifications
You must be signed in to change notification settings - Fork 557
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update BuildKit dependency to use upstream Wait #5808
Conversation
Other similar Without methods, such as `container.WithoutMount` do not fail if the target is not present. However, previously in BuildKit, the llb.WithAllowNotFound was never explicitly required. Updating to the newer BuildKit correctly respects this option, so we need to include llb.WithAllowNotFound directly. Signed-off-by: Justin Chadwell <me@jedevc.com>
14d1ea7
to
b7b07b0
Compare
Signed-off-by: Justin Chadwell <me@jedevc.com>
Signed-off-by: Justin Chadwell <me@jedevc.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return workerInfo, nil | ||
} | ||
time.Sleep(retryPeriod) | ||
ctx, cancel := context.WithTimeout(ctx, 10*time.Minute) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return []string{srctypes.HTTPSScheme} | ||
} | ||
|
||
func (hs *httpSource) Identifier(scheme, ref string, attrs map[string]string, platform *pb.Platform) (source.Identifier, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
platform isn't used in the function, should you use it as parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to take it as a parameter (it's part of the upstream interface). However, HTTP sources shouldn't change their outputs depending on platform - unlike image sources, see:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 - looks great!
This allow us to replace our custom logic for waiting for buildkit to be ready with the logic implemented upstream in moby/buildkit#4200.
Additionally, we need a minor fix to ensure that
Directory.Without
continues working, since due to a bug in buildkit, allow not found was effectively always enabled (see moby/buildkit#4051).We also need to import some additional logic from buildkit now that the sources logic is reasonably significantly moved around, this hopefully enables the removal of the encode id hack as a follow-up.