-
Notifications
You must be signed in to change notification settings - Fork 36
Open
Labels
Milestone
Description
[标题] 在 libfuse-fs::passthroughfs 中支持 bind mount,以支持容器的卷管理
[任务] 在现有 libfuse-fs 的 passthroughfs 中增加对 bind mount 的支持,实现用户态路径挂载到 overlay merged 层的功能,不依赖内核 mount 特权,同时 overlayfs 可继续依赖 passthroughfs 使用该功能。
[任务分值] 70 分
[背景描述] 容器场景中,常需要将宿主目录挂载到 overlay merged 层。传统 bind mount 依赖内核权限(CAP_SYS_ADMIN),在 rootless 容器中无法直接使用。 为了增强 libfuse-fs 的灵活性和兼容性,需要在 passthroughfs 用户态层实现 bind mount 功能,使容器可以访问宿主路径而不依赖内核 mount,同时 overlayfs 依赖 passthroughfs 的逻辑可以自然使用该 bind mount 功能。
[需求描述]
- 在 passthroughfs 中支持用户态 bind mount,实现 merged 路径映射到宿主路径。
- 在 FUSE lookup / open / read / write 等回调中处理 bind mount 路径请求。
- 目录遍历(readdir)在 bind mount 路径下正确显示宿主目录内容。
- 可选择只读或可写模式,写入宿主路径时支持直接写入。
- 避免路径冲突、循环挂载,确保 overlay 上下文语义正确。
- 保证性能和安全性,遵循 rootless 用户权限限制。
- overlayfs 可以继续依赖 passthroughfs,通过 bind mount 访问宿主路径。
[代码标准]
- 所有 PR 提交必须签署 Signed-off-by 和 使用 GPG 签名,即提交代码时(使用 git commit 命令时)至少使用 -s -S 两个参数,参考 Contributing Guide ;
- 所有 PR 提交必须通过 GitHub Actions 自动化测试,提交 PR 后请关注 GitHub Actions 结果;
- 代码注释均需要使用英文;
[PR 提交地址]
提交到 rk8s 仓库的 main 分支 libfuse-rs 目录;
[开发指导]
认领任务参考 r2cn 开源实习计划 - 任务认领与确认;
[导师及邮箱]
请申请此题目的同学使用邮件联系导师,或加入到 R2CN Discord 后在 #p-rk8s 频道和导师交流。
Quanyi Ma [email protected]
[备注]
认领实习任务的同学,必须完成测试任务和注册流程,请参考:
- r2cn 开源实习计划 - 测试任务
- r2cn 开源实习计划 - 学生注册与审核
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
In Progress