Skip to content

Commit 51492d6

Browse files
committed
spfs: add an option for mounting overlayfs layers using syscalls
Teach spfs to mount /spfs using direct overlayfs syscalls. This is provided as an opt-in feature so that users can test this alongside the current "mount"-based implementation. If no issues are encountered then this can be made the default behavior in the future. This approach avoids the command-line length limits that are present when using the "mount" command to create the /spfs mount. Related-to: #968 Related-to: #1164
1 parent 286d1a9 commit 51492d6

File tree

3 files changed

+349
-22
lines changed

3 files changed

+349
-22
lines changed

crates/spfs/src/config.rs

+5
Original file line numberDiff line numberDiff line change
@@ -367,6 +367,11 @@ pub struct Filesystem {
367367
/// directly in the annotation layer.
368368
#[serde(default = "Filesystem::default_annotation_size_limit")]
369369
pub annotation_size_limit: usize,
370+
371+
/// Use direct syscalls when performing overlayfs mounts when true.
372+
/// Use the "mount" command when false. Defaults to false.
373+
#[serde(default)]
374+
pub use_mount_syscalls: bool,
370375
}
371376

372377
impl Filesystem {

0 commit comments

Comments
 (0)