Can create network filter rules
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
use crate::libvirt_lib_structures::XMLUuid;
|
||||
use crate::libvirt_rest_structures::nw_filter::NetworkFilterName;
|
||||
use clap::Parser;
|
||||
use std::net::IpAddr;
|
||||
use std::path::{Path, PathBuf};
|
||||
@ -252,6 +253,11 @@ impl AppConfig {
|
||||
pub fn net_definition_path(&self, name: &str) -> PathBuf {
|
||||
self.definitions_path().join(format!("net-{name}.json"))
|
||||
}
|
||||
|
||||
pub fn net_filter_definition_path(&self, name: &NetworkFilterName) -> PathBuf {
|
||||
self.definitions_path()
|
||||
.join(format!("nwfilter-{}.json", name.0))
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, serde::Serialize)]
|
||||
|
Reference in New Issue
Block a user