dotnet / dotnet-docker

Docker images for .NET and the .NET Tools.
https://hub.docker.com/_/microsoft-dotnet
MIT License
4.44k stars 1.93k forks source link

Create an HTTP/3 / QUIC sample #5468

Open lbussell opened 4 months ago

lbussell commented 4 months ago

HTTP/3 is fully supported in .NET 7+, but we have no formal samples showing how to enable that scenario. We get issues or questions from time to time about how to enable HTTP/3 in our various images, so we should add a sample for it.

Related

lbussell commented 4 months ago

[Triage] Enabling HTTP/3 is fairly simple if libmsquic is installed. Our samples should focus on installing msquic if we don't decide to include it in our extra images (https://github.com/dotnet/dotnet-docker/issues/4385). If msquic is included in our images somehow, then we should make sure we've documented how to use it in each scenario (distroless, Chiseled, non-extra images, etc.) but a sample may not be necessary.

polarathene commented 1 day ago

@andrew-from-toronto pinging you since expressed interested in this #4385

I've shared guidance for libmsquic both with and without chisel: https://github.com/dotnet/dotnet-docker/discussions/4823#discussioncomment-10770991

My approach for chisel is a bit hacky, but as per the reference link I provide, it's fairly simple to identify any breaking changes should they occur. I wasn't 100% sure on if skipping lttng from the package was ok, but the app I tested with ran without complaints.

As for an official solution with chisel, smaller images could be published to a registry to distribute the libraries. You could then COPY them over which should work quite well at being flexible composition wise. If taking that approach, might help to document the compatibility like I did. With the right semver tags that should be reliable 👍

That said, chisel is getting dpkg slice which might be the better way to go 😅