-
Notifications
You must be signed in to change notification settings - Fork 343
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
Pipeline Editor: Extend data volume node property #2961
Conversation
Allow for customization of the read_only and sub_path attributes
Thanks for making a pull request to Elyra! To try out this branch on binder, follow this link: |
@marthacryan @ajbozarth can we render boolean default node values as checkboxes, like we do for node properties? |
I just realized that using a checkbox as input widget for boolean values causes a usability issue.
Edit: For this PR/scenario the current behavior is the desired one, because the pipeline default value is the combination of all attributes (mount path, pvc name, sub path, read-only). If we were to treat each attribute as a default things would get confusing very quickly. However, the issue should apply to boolean properties:
|
This seems more of a matter of using the wrong default value in the schema than a usability issue relative to booleans and checkboxes. |
(Our comments crossed.)
Yes. This is where I thought your original comment was heading and, if "not-set" is a third, distinct, state, then boolean is probably not the right choice. Typically, some other (higher scoped) attribute would reflect "not-set". |
Yep, sorry. I also forgot that we already do this for the When no pipeline default value is set, these are the choices a user has when configuring a node property value: When a pipeline default value is set, these are the choices a user has when configuring a node property value (the default is pre-selected): For the sake of consistency, should we always render booleans as select lists instead of checkboxes to avoid using different widgets to collect input for the same data type? |
I find it confusing for the case when no pipeline default exists that neither True nor False are selected and I have no idea which of the two values would be used. In addition, when a pipeline default does exist, I find the "duplicated" value (True in this case) a little confusing and would rather there still just be two options - with the pipeline default indication placed on the applicable value. Could we make a rule that all boolean properties must specify a default (and/or if a default is not specified, |
…o extend-volume-property
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.
Just two minor comments below from me! Otherwise, code is looking good to me!
Co-authored-by: Kiersten Stokes <kierstenstokes@gmail.com>
…o extend-volume-property
PR should now be in synch with |
@marthacryan - is the checkbox change made here or in the pipeline-editor repo? |
re #2961 (comment)
|
Discussed this in today's dev meeting. The change will be delivered in a separate PR for #2967 |
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.
LGTM!
Mounts:
/mnt/vol1 from test-2-volume (ro,path="sub-dir-1")
/var/run/argo from var-run-argo (rw)
/var/run/secrets/kubernetes.io/serviceaccount from default-editor-token-jf5kd (ro)
Requires #2957RESOLVEDThis PR enables users to optionally customize the
read_only
andsub_path
attributes of the data volume property.The new attributes are supported for the Kubeflow Pipelines and Apache Airflow runtimes and apply to generic and custom components.
Benefits
The main benefit of this enhancement is more fine granular access control for mounted volumes, as illustrated in the following scenarios:
In both scenarios the underlying filesystem contains the same directories, each including several files.
Pre-PR behavior
/
,/inputs/...
, etc)/
,/inputs/...
, etc)This implies that the entire filesystem is unprotected, because every single file can be accessed, and in the case of scenario 2 manipulated.
post-PR behavior
/
,/inputs/...
, etc) or parts of the filesystem (only/inputs/...
) can be granted, as appropriate/
,/inputs/...
, etc) or parts of the filesystem (read access for/inputs/...
, write access to/outputs/...
) can be granted, as appropriateNote that if the PVC's access mode is read-only, setting the
read_only
attribute toFalse
does not grant write access.Closes #2953
What changes were proposed in this pull request?
See above
How was this pull request tested?
make docs
Correct behavior can be confirmed by inspecting the node's pod (e.g.
kubectl describe pod -n kubeflow-user-example-com <pod-id>
)Developer's Certificate of Origin 1.1