MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / test_driver_with_extensions

Function test_driver_with_extensions

crates/openshell-driver-vm/src/driver.rs:6803–6825  ·  view source on GitHub ↗
(extensions: LifecycleExtensionRegistry)

Source from the content-addressed store, hash-verified

6801 use crate::runtime::VmBackend;
6802
6803 fn test_driver_with_extensions(extensions: LifecycleExtensionRegistry) -> VmDriver {
6804 let (events, _) = broadcast::channel(WATCH_BUFFER);
6805 VmDriver {
6806 config: VmDriverConfig {
6807 openshell_endpoint: "http://127.0.0.1:8080".to_string(),
6808 vcpus: 2,
6809 mem_mib: 2048,
6810 gpu_vcpus: 8,
6811 gpu_mem_mib: 16384,
6812 ..Default::default()
6813 },
6814 launcher_bin: PathBuf::from("openshell-driver-vm"),
6815 registry: Arc::new(Mutex::new(HashMap::new())),
6816 image_cache_lock: Arc::new(Mutex::new(())),
6817 events,
6818 gpu_inventory: None,
6819 subnet_allocator: Arc::new(std::sync::Mutex::new(SubnetAllocator::new(
6820 Ipv4Addr::new(10, 0, 128, 0),
6821 17,
6822 ))),
6823 lifecycle_extensions: Arc::new(extensions),
6824 }
6825 }
6826
6827 #[derive(Debug)]
6828 struct QemuRequiringExtension {

Calls

no outgoing calls

Tested by

no test coverage detected