Skip to content
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

bake: fix entitlements path checks for local outputs #2834

Merged
merged 2 commits into from
Dec 6, 2024

Conversation

tonistiigi
Copy link
Member

Previous check based on dest attributes was not correct as the attributes already get converted before validation happens.

Because the local path is not preserved for single-file outputs and gets replaced by io.Writer, a temporary array variable was needed. This value should instead be added to ExportEntry struct in BuildKit in future revision.

Previous check based on dest attributes was not correct
as the attributes already get converted before validation happens.

Because the local path is not preserved for single-file
outputs and gets replaced by io.Writer, a temporary array variable
was needed. This value should instead be added to ExportEntry
struct in BuildKit in future revision.

Signed-off-by: Tonis Tiigi <[email protected]>
If override specifies a path, mark it automatically allowed
so there is no need to use duplicate flags for defining the
same feature.

Signed-off-by: Tonis Tiigi <[email protected]>
@tonistiigi tonistiigi force-pushed the bake-entitlements-output-fix branch from d488584 to dd596d6 Compare December 3, 2024 01:16
@tonistiigi
Copy link
Member Author

Added another commit to automatically allow paths that are set via --set flags(for outputs, secrets and remote cache). This is to avoid the need to use both --set and --allow for the same paths. This also helps with the testsuite where this is a common pattern.

Copy link
Member

@crazy-max crazy-max left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call on allowing automatically for overrides, might need a small note in our docs about this (cc @dvdksn)

@tonistiigi tonistiigi merged commit d4eca07 into docker:master Dec 6, 2024
122 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants