Running web server on a single AWS Lambda



I’m wondering if anyone managed to do similar to this Ruby implementation with Rust?

What I would like to do is to run a single AWS Lambda (as opposed to lambda per each endpoint).
To do that, I’d need to do usual routing (via actix.web or maybe rocket when it’ll be stable or similar) from within lambda.

Obviously I can’t just bind to a port as the request details will need to be assembled manually from the lambda (similarly to the Ruby example).

Also, it would be very beneficial if I could reuse the same routing on lambda as well as locally running Rust web server (with slightly different “entry points” ).

So I would appreciate some pointers if people have done this before and maybe some examples.