Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn main() {
- // Logger
- env::set_var("RUST_LOG", "simple_proxy,ox");
- pretty_env_logger::init();
- // Config
- dotenv().ok();
- let config = config::Config::new();
- info!("Config: {:?}", config);
- let mut proxy = SimpleProxy::new(config.port, config.environment);
- // Middlewares
- proxy.add_middleware(Routing::new(&config));
- // proxy.add_middleware(Routing::new(config));
- // proxy.add_middleware(Routing::new(config));
- // Start proxy
- proxy.run();
- }
Add Comment
Please, Sign In to add comment