Closed bergwolf closed 3 years ago
This sounds like a very good idea to me.
Related: https://github.com/kata-containers/runtime/pull/357#issuecomment-394558386.
/cc @grahamwhaley.
@bergwolf better organization by the introduction of known subdirs, this SGTM !
Sounds good to me as well. Even if we've not actually seen any issues with the current nested/re-used directory setup, it makes a lot of sense to split these out into obviously named/placed subdirs.
The only issue I can think of is that we'll need to keep the subdir names short - see https://github.com/kata-containers/runtime/pull/294.
I don't think this is an issue since we're not referencing any socket path from there.
@bergwolf that sounds like a good idea. Because kata keeps everything in shared 9p I introduced /ephemeral/
in https://github.com/kata-containers/runtime/pull/307
But If we have a sandbox specific storage like /run/kata-containers/storages/
, as you have suggested above, then we can have ephemeral go in /run/kata-containers/storages/ephemeral/<volume-name>
Currently inside the guest, we mount all storages under
kataGuestSharedDir
that is actually the mount point of 9pfs. This might confuse the 9pfs, e.g., these internal volume mountpoints directories are also visible to host side via 9pfs. IMO we should consider refactor a bit so that we have following mountpoint structure:/run/kata-containers/storages/
that keeps all the sandbox level storage/run/kata-containers/shared/
that mounts the one and only 9pfs share/run/kata-containers/containers/<cid>/
that keeps each containers mnt namespace mountpoints (bind mount from a subdirectory of either/run/kata-containers/storages/
or/run/kata-containers/shared/
.)@amshinde WDYT?