Skip to content

Passthrough some directory under /home #331

Closed as not planned
Closed as not planned

Description

@Fatmice

I would like to passthrough a directory under /home to the container. How do I go about doing this? Is there some config files that I can edit for each container?

Activity

  1. maxwell-k commented on Nov 15, 2019

    @maxwell-k

    Did you check in /var/run/host/var/home? On Fedora Silverblue 30 this contains the home directory.

  2. Fatmice commented on Nov 15, 2019

    @Fatmice
    Author

    I'm on Fedora 31, the path /var/run/host/var/home is not found. There are various things under /var/run/host/var but not the home directory. I have intel compiler installed under /home/intel and to use it normally one must source the file psxevars.sh when lauching a shell, which is located under /home/intel/parallel_studio_xe__/

  3. maxwell-k commented on Nov 15, 2019

    @maxwell-k

    Sorry I am a version behind, all I can suggest is having a look around in /var/run/host. From the docs I still think /home should be a symlink to /var/home; but I can't test at the moment. Good luck.

  4. debarshiray commented on Nov 19, 2019

    @debarshiray
    Member

    The definition of /home depends on whether you are on Silverblue or not. On Silverblue /home is a symbolic link to /var.

    Containers created with recent versions of Toolbox make the host's /var available at /run/host/var inside the container. So, if you use /var/intel on the host, instead of /home/intel, then what @maxwell-k suggested should work.

  5. markstos commented on Dec 26, 2019

    @markstos

    This relates to #183, which is a feature request not mount /home by default and instead support mounting just specific directories in the container.

  6. debarshiray commented on Jan 10, 2020

    @debarshiray
    Member

    I am tentatively closing this based on the idea of using /var/intel instead of /home/intel.

  7. Fatmice commented on Jan 11, 2020

    @Fatmice
    Author

    Sorry, but I disagree with that notion. /var should not be a dumping place for programs and tool-chains...And honestly, I should get to decide where I want to put my tool-chains...They were installed to /home, many years ago before I came to use podman or toolbox. Normally, I would have opted to put them under /opt but did not due to partition layout.

  8. markstos commented on Jan 13, 2020

    @markstos

    @Fatmice One of Red Hat's own developers suggested that there be an option to add additional mount points under / on Silverblue over a year ago, but the idea was never acted on:

    coreos/rpm-ostree#1711

    I gave up and moved on to Arch Linux. Silverblue is too inflexible and a key issue like this is seeing little progress. Maybe in another couple years I'll check back in and see what progress there's been.

    Maybe there's merit to having just one r/w partition and have that be named "/var", but there are multiple decades of software built on the assumption that "/home" physically exists.

    For Silverblue to gain traction faster it seems prudent to support some kind of transition or compatibility solution where other mount points can be supported, as one their own team members suggested.

  9. Fatmice commented on Jan 13, 2020

    @Fatmice
    Author

    @markstos I personally do not mind if there is only one r/w partition and it must be /var but at least allow mounting something else read-only, like /home/intel... Or at least someway to pass an abitrary link through that's read-only. I could maybe understand why they find this slippery as it might somehow introduces backdoors where one could escape, but then again I don't think that alone should make this thing so limiting.

  10. debarshiray commented on Aug 5, 2022

    @debarshiray
    Member

    Containers created with recent versions of Toolbox make the host's
    /var available at /run/host/var inside the container.

    Even more recent versions of Toolbx (newer than 0.0.99.3, to be precise) make the entire / from the host available at /run/host. So, containers created with Toolbx >= 0.0.99.3 will have /run/host/home regardless of whether it's Fedora Silverblue or Workstation.

  11. Fatmice commented on Aug 6, 2022

    @Fatmice
    Author

    This is very good to hear

  12. markstos commented on Aug 8, 2022

    @markstos

    Even more recent versions of Toolbx (newer than 0.0.99.3, to be precise) make the entire / from the host available at /run/host.

    Where is this document? I don't see it in the main README or in the docs for the create command:

    https://github.com/containers/toolbox/blob/main/doc/toolbox-create.1.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions