pub struct CowOptions {
pub data_dir: PathBuf,
pub block_tools: Arc<dyn BlockTools>,
pub dmsetup_candidates: Vec<PathBuf>,
}Expand description
What a CowManager needs from its environment.
CowOptions::new fills in the reference environment — the System
VM’s userland — so today’s callers pass a data directory and nothing
else; a composer on a different userland overrides the fields it owns.
Fields§
§data_dir: PathBufData directory; COW files live under {data_dir}/cow/.
block_tools: Arc<dyn BlockTools>Loop-device and block-size operations.
dmsetup_candidates: Vec<PathBuf>Where to look for dmsetup. The first entry that exists and answers
dmsetup version is used; none usable degrades the manager to
copy-mode fallback (every setup fails with an actionable error).
Implementations§
Source§impl CowOptions
impl CowOptions
Sourcepub fn new(data_dir: impl Into<PathBuf>) -> CowOptions
pub fn new(data_dir: impl Into<PathBuf>) -> CowOptions
The reference environment: busybox at BusyboxBlockTools::DEFAULT_PATH
and the stock-distro dmsetup search list.
Auto Trait Implementations§
impl !RefUnwindSafe for CowOptions
impl !UnwindSafe for CowOptions
impl Freeze for CowOptions
impl Send for CowOptions
impl Sync for CowOptions
impl Unpin for CowOptions
impl UnsafeUnpin for CowOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more