Implement config file parsing and precedence with CLI
This commit is contained in:
+2
-2
@@ -167,7 +167,7 @@ fn ro_bind_under_tmpfs(cmd: &mut Command, base: &str, paths: &[&str]) {
|
||||
|
||||
fn add_rw_bind(cmd: &mut Command, path: &Path) -> Result<(), SandboxError> {
|
||||
if !path.exists() {
|
||||
return Err(SandboxError::RwPathMissing(path.to_path_buf()));
|
||||
return Err(SandboxError::PathMissing(path.to_path_buf()));
|
||||
}
|
||||
cmd.arg("--bind").arg(path).arg(path);
|
||||
Ok(())
|
||||
@@ -175,7 +175,7 @@ fn add_rw_bind(cmd: &mut Command, path: &Path) -> Result<(), SandboxError> {
|
||||
|
||||
fn add_ro_bind(cmd: &mut Command, path: &Path) -> Result<(), SandboxError> {
|
||||
if !path.exists() {
|
||||
return Err(SandboxError::RoPathMissing(path.to_path_buf()));
|
||||
return Err(SandboxError::PathMissing(path.to_path_buf()));
|
||||
}
|
||||
cmd.arg("--ro-bind").arg(path).arg(path);
|
||||
Ok(())
|
||||
|
||||
Reference in New Issue
Block a user