Integrated opnsense-config API in harmony, pretty easy, pretty happy. very much encouraging

This commit is contained in:
jeangab
2024-11-26 15:58:42 -05:00
parent d30e909b83
commit 9c18c8be6d
13 changed files with 108 additions and 146 deletions

View File

@@ -1,5 +1,5 @@
use std::{
net::Ipv4Addr,
net::IpAddr,
sync::Arc,
time::{SystemTime, UNIX_EPOCH},
};
@@ -20,7 +20,7 @@ use super::OPNsenseShell;
#[derive(Debug)]
pub struct SshOPNSenseShell {
host: (Ipv4Addr, u16),
host: (IpAddr, u16),
credentials: SshCredentials,
ssh_config: Arc<Config>,
}
@@ -78,11 +78,7 @@ impl SshOPNSenseShell {
wait_for_completion(&mut channel).await
}
pub fn new(
host: (Ipv4Addr, u16),
credentials: SshCredentials,
ssh_config: Arc<Config>,
) -> Self {
pub fn new(host: (IpAddr, u16), credentials: SshCredentials, ssh_config: Arc<Config>) -> Self {
Self {
host,
credentials,