cors-proxy 1.0.2

Quick and dirty cors proxy
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use clap::Parser;
use std::net::Ipv4Addr;

#[derive(Parser, Debug)]
#[command(version, about, long_about = None)]
pub struct CliOptions {
    #[arg(long, default_value = "127.0.0.1")]
    host: Ipv4Addr,
    #[arg(short, long, default_value = "3000")]
    port: u16,
}

pub async fn cli_main() -> Result<(), std::io::Error> {
    let args = CliOptions::parse();
    crate::server::serve_proxy(args.host, args.port).await
}