Closed Swoorup closed 1 year ago
I can get it working without axum-tonic using tonic-web. But....
let addr = "127.0.0.1:8080".parse().unwrap();
let echo_service = tonic_web::config()
.allow_all_origins()
.allow_credentials(true)
.expose_headers([ACCESS_CONTROL_ALLOW_ORIGIN])
.enable(EchoServer::new(Echo::default()));
Server::builder().accept_http1(true).add_service(echo_service).serve(addr).await;
Solved without using axum-tonic: https://github.com/hyperium/tonic/discussions/1111#discussioncomment-4069201
I tried running a simple Echo example from the tonic sources using this axum. It seems I am unable to get the CORS policy working any ideas?