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

Option to support volume mounts outside user $HOME #107

Closed
mharwani opened this issue Dec 8, 2022 · 1 comment · Fixed by #128
Closed

Option to support volume mounts outside user $HOME #107

mharwani opened this issue Dec 8, 2022 · 1 comment · Fixed by #128
Assignees
Labels
enhancement New feature or request

Comments

@mharwani
Copy link
Member

mharwani commented Dec 8, 2022

What is the problem you're trying to solve?.
Currently, finch containers can only access resources inside user's home directory. I think there should be more flexibility in mount locations exposed by the virtual machine.

Describe the feature you'd like
Allow users to configure additional mount locations during VM start. These locations will be accessible to containers through commands such as finch run or finch cp.

Additional context
Adding an option to configure new mount locations in ${HOME}/.finch/finch.yaml seems like a good approach. And perhaps through a command line flag, for eg:

finch vm start -v /tmp/data
@sam-berning sam-berning added the enhancement New feature or request label Dec 8, 2022
@ningziwen ningziwen self-assigned this Dec 14, 2022
@ningziwen
Copy link
Member

ningziwen commented Dec 14, 2022

Not all the non-home directories have the use case of being workspace directories. Users mostly want to work in their customized non-home directories instead of system directories.

Also not all of them can be mounted to VM in Lima. For example, if Finch passes “/” as the mount point to Lima, it will return error.

FATA[0000] the YAML is invalid, saved the buffer as "lima.REJECTED.yaml": field `mounts[0].location` must not be a system path such as /etc or /usr

So I’d like a feature that makes non-home directories a field in Finch config.
The new field name is TBD. Using "additional_workspace_locations" as example below.

An example yaml will be:

cpus: 4
memory: 4GiB
additional_workspace_locations:
    - /Volumes/mydir

ningziwen added a commit that referenced this issue Dec 20, 2022
Signed-off-by: Ziwen Ning <ningziwe@amazon.com>

Issue #, if available:
#107

*Description of changes:*
Doc

*Testing done:*



- [ X ] I've reviewed the guidance in CONTRIBUTING.md


#### License Acceptance

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

Signed-off-by: Ziwen Ning <ningziwe@amazon.com>
@ningziwen ningziwen linked a pull request Dec 21, 2022 that will close this issue
ningziwen added a commit that referenced this issue Dec 26, 2022
Signed-off-by: Ziwen Ning <ningziwe@amazon.com>

Issue #, if available:
#107

*Description of changes:*
add config to support additional directories according to the doc added
in #123

*Testing done:*



- [ X ] I've reviewed the guidance in CONTRIBUTING.md


#### License Acceptance

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

Signed-off-by: Ziwen Ning <ningziwe@amazon.com>
ahsan-z-khan pushed a commit to ahsan-z-khan/finch that referenced this issue Jan 11, 2023
…inch#123)

Signed-off-by: Ziwen Ning <ningziwe@amazon.com>

Issue #, if available:
runfinch#107

*Description of changes:*
Doc

*Testing done:*



- [ X ] I've reviewed the guidance in CONTRIBUTING.md


#### License Acceptance

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

Signed-off-by: Ziwen Ning <ningziwe@amazon.com>
ahsan-z-khan pushed a commit to ahsan-z-khan/finch that referenced this issue Jan 11, 2023
Signed-off-by: Ziwen Ning <ningziwe@amazon.com>

Issue #, if available:
runfinch#107

*Description of changes:*
add config to support additional directories according to the doc added
in runfinch#123

*Testing done:*



- [ X ] I've reviewed the guidance in CONTRIBUTING.md


#### License Acceptance

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

Signed-off-by: Ziwen Ning <ningziwe@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: v0.2.0
Development

Successfully merging a pull request may close this issue.

3 participants