remote-block-device-backup/remote-block-device-backup-.../src/main.rs

22 lines
549 B
Rust

#[macro_use]
extern crate derive_new;
extern crate remote_block_device_backup_common;
use remote_block_device_backup_common::handle_client;
mod cli;
fn main() {
let cli_args = cli::get_arguments_parsed();
let mut stream: std::net::TcpStream =
std::net::TcpStream::connect(format!("{}:{}", cli_args.ip_address, cli_args.port_number))
.unwrap();
handle_client(
&mut stream,
cli_args.data_store,
cli_args.target_block_device,
cli_args.block_size,
cli_args.check_size,
);
}