Make the temp mount as ready only in container WithVolumes#6593
Make the temp mount as ready only in container WithVolumes#6593fuweid merged 1 commit intocontainerd:mainfrom
Conversation
Signed-off-by: Qiutong Song <[email protected]>
|
Hi @qiutongs. Thanks for your PR. I'm waiting for a containerd member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/assign fuweid ruiwen-zhao Random-Liu |
|
@qiutongs: GitHub didn't allow me to assign the following users: ruiwen-zhao. Note that only containerd members, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/cc ruiwen-zhao |
| } | ||
| // Since only read is needed, append ReadOnly mount option to prevent linux kernel | ||
| // from syncing whole filesystem in umount syscall. | ||
| if len(mounts) == 1 && mounts[0].Type == "overlay" { |
There was a problem hiding this comment.
I am thinking to define this as a util function so that it can be used by everyone. Thus we don't need to copy code from #6478. But I am not sure what a good place is. Any suggestion is welcomed.
|
Build succeeded.
|
Signed-off-by: Qiutong Song [email protected]
Inspired by #6478
This improves the WithVolumes by making the temporary mount as read only. The mount is only used to copy files to image volume. Read-only mount will prevent linux kernel from syncing whole filesystem in umount syscall.