mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-26 23:38:31 +00:00
Merge pull request #7306 from justxuewei/none-network-model
runtime-rs: Do not scan network if network model is "none"
This commit is contained in:
commit
f6a51a8a78
@ -49,7 +49,13 @@ struct NetworkWithNetnsInner {
|
||||
impl NetworkWithNetnsInner {
|
||||
async fn new(config: &NetworkWithNetNsConfig, d: Arc<RwLock<DeviceManager>>) -> Result<Self> {
|
||||
let entity_list = if config.netns_path.is_empty() {
|
||||
warn!(sl!(), "skip to scan for empty netns");
|
||||
warn!(sl!(), "Skip to scan network for empty netns");
|
||||
vec![]
|
||||
} else if config.network_model.as_str() == "none" {
|
||||
warn!(
|
||||
sl!(),
|
||||
"Skip to scan network from netns due to the none network model"
|
||||
);
|
||||
vec![]
|
||||
} else {
|
||||
// get endpoint
|
||||
|
Loading…
Reference in New Issue
Block a user