From 76a6880605195d253dd4837204a252816bd5a396 Mon Sep 17 00:00:00 2001 From: Andrew Clayton Date: Tue, 28 Nov 2023 23:53:57 +0000 Subject: Add a wasi-http echo-request component in C This adds a wasi-http version of luw-echo-request.c[0] This works under the wasmtime v15 CLI serve command. e.g $ ~/src/c/wasm/wasmtime-v15.0.0-x86_64-linux/wasmtime serve c/wasi-http/echo-request/component.wasm Serving HTTP on http://0.0.0.0:8080/ $ curl localhost:8080/hello *** Welcome to WebAssembly with wasi-http / C *** [Request Info] REQUEST_PATH = /hello METHOD = GET QUERY = [Request Headers] host = localhost:8080 user-agent = curl/8.2.1 accept = */* [0]: Signed-off-by: Andrew Clayton --- .../echo-request/wasi_snapshot_preview1.reactor.wasm | Bin 0 -> 97017 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 c/wasi-http/echo-request/wasi_snapshot_preview1.reactor.wasm (limited to 'c/wasi-http/echo-request/wasi_snapshot_preview1.reactor.wasm') diff --git a/c/wasi-http/echo-request/wasi_snapshot_preview1.reactor.wasm b/c/wasi-http/echo-request/wasi_snapshot_preview1.reactor.wasm new file mode 100644 index 0000000..c8320e0 Binary files /dev/null and b/c/wasi-http/echo-request/wasi_snapshot_preview1.reactor.wasm differ -- cgit