-
Notifications
You must be signed in to change notification settings - Fork 65
Volume options - allow nocreate option #585
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Ygal Blum <[email protected]>
|
This change is required as a first step for containers/podman#27867 |
|
✅ A new PR has been created in buildah to vendor these changes: containers/buildah#6628 |
|
LGTM |
mtrmac
left a comment
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.
I know ~nothing about this code, but at a first glance I share the concern in https://github.com/containers/podman/pull/27867/changes#r2676413266 : ValidateVolumeOpts is also called from Buildah. Isn’t it, after this PR, going to start passing the nocreate string to code which is not ready to consume it?
What do we do?
- One option might be to implement the option in Buildah as well. (Using some shared code??)
- Or do we add a parameter (
supportsNoCreate?) toValidateVolumeOpts(breaking API means a Buildah PR would need to be included, or adding a new function here).
|
@mtrmac I agree with the issue you raised. This is why I initially implemented the handling of this flag directly in Podman. But, then following @Luap99's comment: containers/podman#27867 (comment) I moved it here. As for how to continue from here.
|
|
@Luap99 , @containers/podman-maintainers ? |
|
Buildah doesn't make named volumes, but all these options also apply to bind mounts as well. IMO, appropriate solution is to allow the option here, but have Buildah error if the option is actually passed (which, honestly, will probably happen anyways...) |
|
If that's the case, I think the simplest solution will be to add a new api:
|
|
buildah already has to have some validation logic of its own to reject flags it doesn't recognize for build-time cache and bind mounts, and as long as this function accepts a superset of what it does, it won't have an effect. So I don't think the current PR will affect it. |
No description provided.