elliottt opened PR #7545 from elliottt:trevor/serve-host
to bytecodealliance:main
:
Ensure that the scheme and authority are populated in the requests given to the incoming handler with
wasmtime serve
. We prefer theHost
header if it's available, falling back on the existing value of theauthority
in the request. Additionally, we fall back onhttp
as the scheme when none was present.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
elliottt requested alexcrichton for a review on PR #7545.
elliottt requested wasmtime-core-reviewers for a review on PR #7545.
elliottt requested wasmtime-default-reviewers for a review on PR #7545.
elliottt edited PR #7545:
Ensure that the scheme and authority are populated in the requests given to the incoming handler with
wasmtime serve
. We prefer theHost
header if it's available, falling back on the existing value of theauthority
in the request. Additionally, we fall back onhttp
as the scheme when none was present. This behavior mirrors what https://github.com/fastly/vicroy does for request handling, and ensures that runtimes that require an incoming authority to be set (like the javascript runtime) have one available.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
elliottt edited PR #7545:
Ensure that the scheme and authority are populated in the requests given to the incoming handler with
wasmtime serve
. We prefer theHost
header if it's available, falling back on the existing value of theauthority
in the request. Additionally, we fall back onhttp
as the scheme when none was present. This behavior mirrors what https://github.com/fastly/vicroy does for request handling, and ensures that runtimes that require an incoming authority to be set (like the javascript runtime) have one available.cc @tschneidereit @JakeChampion
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
elliottt requested pchickey for a review on PR #7545.
guybedford submitted PR review.
guybedford created PR review comment:
Why not default to
HTTPS
? Is this also to align with Viceroy?
elliottt submitted PR review.
elliottt created PR review comment:
wasmtime serve
doesn't currently support listening on https, but if that changes in the future we could make it default to what the server's listening on.
pchickey submitted PR review.
elliottt merged PR #7545.
Last updated: Dec 23 2024 at 12:05 UTC