wip
This commit is contained in:
@@ -25,7 +25,7 @@ fn map_to_vmspec(spec: Map) -> Result<VmSpec, Box<EvalAltResult>> {
|
||||
let memory_mb = get_int(&spec, "memory_mb").unwrap_or(512) as u32;
|
||||
let cmdline = get_string(&spec, "cmdline");
|
||||
let extra_args = get_string_array(&spec, "extra_args");
|
||||
|
||||
|
||||
Ok(VmSpec {
|
||||
id,
|
||||
kernel_path,
|
||||
@@ -37,6 +37,7 @@ fn map_to_vmspec(spec: Map) -> Result<VmSpec, Box<EvalAltResult>> {
|
||||
memory_mb,
|
||||
cmdline,
|
||||
extra_args,
|
||||
net_profile: None,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -76,6 +77,8 @@ fn vmspec_to_map(s: &VmSpec) -> Map {
|
||||
} else {
|
||||
m.insert("extra_args".into(), Dynamic::UNIT);
|
||||
}
|
||||
// net_profile not exposed in Rhai yet; return UNIT for now
|
||||
m.insert("net_profile".into(), Dynamic::UNIT);
|
||||
m
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user