> Deployment with Rust backend programs in general can be less than ideal due to having to use Dockerfiles,<p>Actually, in my experience, Rust is one of the best languages for ease of deployment (for much the same reason as Go). Rust/Cargo produces self-contained statically linked binaries. Rust/Cargo also has a real nice cross-compiling story. Often my deployment will be to build the binary and then basically scp the binary and supporting files (such as html/config) to the target. You don't really need Docker.
Is it safe to expose to the internet[0]? I’m still looking for a Rust web framework that supports eg timeouts for idle connections so that it doesn’t crash and burn when it runs out of sockets after a few hours of serving production traffic (let alone being able to survive an intentional slowloris attack) :(<p>[0] I’m ideally hoping for a framework which ticks the same boxes that Go’s `net/http` was ticking in 2016: <a href="https://blog.cloudflare.com/exposing-go-on-the-internet/" rel="nofollow noreferrer">https://blog.cloudflare.com/exposing-go-on-the-internet/</a>
This isn't trolling, it's my genuine ignorance- I thought Actix was the goto web framework for Rust? I don't do a whole lot of Rust and when I do it isn't http router type work so I'm out of the loop here.
I love Axum as well that I also wrote a blog post teaching how to link it up with PostgreSQL and Tokio.<p><a href="https://spacedimp.com/blog/using-rust-axum-postgresql-and-tokio-to-build-a-blog/" rel="nofollow noreferrer">https://spacedimp.com/blog/using-rust-axum-postgresql-and-to...</a>
I've been using Tide with great success lately. Also - for my own projects I haven't used docker lately and just dump the binary with it's configs to the debian box with a systemd configured and so far it's been painless, ymmv.