Skip to content

Conversation

@dmcgowan
Copy link
Member

@dmcgowan dmcgowan commented Jul 7, 2025

Implementation of #11303
Depends on #12025 merged

WIP Items:

  • Update implementation and testing complete
  • Moving runtime implementation down to the task manager complete
  • Passing runtime name to complete
  • More complete documentation complete
* **Add mount manager** ([#12063](https://github.com/containerd/containerd/pull/12063))

  The mount manager is a new service that provides lifecycle management for filesystem mounts
  to support more advanced use cases, such as:
  * **Device formatting** to create formatted filesystems (xfs, ext4) on-demand  
  * **Mount activation** to prepare devices such as loopbacks or network fileystems
  * **Mount transformation** to allow mount arguments to be filled in dynamically from previous mounts
  * **Garbage collection** of mounts to ensure temporary mounts are never leaked

@k8s-ci-robot
Copy link

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

Signed-off-by: Derek McGowan <[email protected]>
Signed-off-by: Derek McGowan <[email protected]>
Create separate package for snapshotter test in metadata package to
prevent circular dependency.

Signed-off-by: Derek McGowan <[email protected]>
Avoid keeping file descriptor open to directory which is getting
removed. Update error handling and wrapping to provide more clarity
around failures.

Signed-off-by: Derek McGowan <[email protected]>
The autoclear may take a bit of time to clear out the file, check
multiple times for the file to get removed before returning an error.

Signed-off-by: Derek McGowan <[email protected]>
Allow task manager to fetch info on runtimes at startup.
Use this info to configure whether the runtime allows formatted mounts.
This info could also be used in the future to enforce policy such as
requiring a pre-known set of runtimes or specific runtime properties.

Signed-off-by: Derek McGowan <[email protected]>
Allow the mount manager to skip handling of custom types. Ensure that
custom types are still working with formatted mounts.

Signed-off-by: Derek McGowan <[email protected]>
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 48 out of 58 changed files in this pull request and generated 3 comments.

Comments suppressed due to low confidence (1)

core/mount/manager/manager.go:1

  • The TODO comment 'IF has sync' is unclear and incomplete. It should be clarified to explain what condition should be checked or removed if no longer needed.
/*

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Let the runtime specify which custom mounts it will support

Signed-off-by: Derek McGowan <[email protected]>
Copy link
Member

@fuweid fuweid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, LGTM

The change is huge. We need more e2e test for this in the follow-up, especially detecting leaky resources.


// metadata_test is used to test the metadata snapshotter implementations
// against the snapshotter test suite.
package metadata_test
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since it's external package, maybe we can put this test in native plugin? it's not a blocker

@github-project-automation github-project-automation bot moved this from Needs Reviewers to Review In Progress in Pull Request Review Oct 3, 2025
@fuweid fuweid added this pull request to the merge queue Oct 3, 2025
Merged via the queue into containerd:main with commit 61ddcd5 Oct 3, 2025
135 of 138 checks passed
@github-project-automation github-project-automation bot moved this from Review In Progress to Done in Pull Request Review Oct 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants