containerd / runwasi

Facilitates running Wasm / WASI workloads managed by containerd
Apache License 2.0
1.01k stars 82 forks source link

Missmatch docs and build #567

Closed erkules closed 2 months ago

erkules commented 2 months ago

Building runwasi I get (shown for wasmtime for simplicity):

containerd-shim-wasmtime-v1
containerd-shim-wasmtime-v1.d

The docs talk about:

- containerd-shim-[ wasmedge | wasmtime | wasmer ]-v1
- containerd-shim-[ wasmedge | wasmtime | wasmer ]d-v1
- containerd-[ wasmedge | wasmtime | wasmer ]d

So there is a suffix missmatch (v1.d vs. d-v1)

I also miss how to build the **d and how to run it

Mossaka commented 2 months ago

Thanks for raising this issue, yes the docs and the built artifacts are mismatched because we have integrated all the binaries into one binary. the containerd-shim-wasmtime-v1 binary uses argv[0] to decide to run as

https://github.com/containerd/runwasi/blob/main/crates/containerd-shim-wasm/src/sandbox/cli.rs#L66-L78

Running make install will automatically copy the same built binary three times, one for each binary, to local bin.

erkules commented 2 months ago

Ok, maybe I should have installed it. Building on for remote machines I intentionally missed that step thx. Is there an example how to run containerd-wasmtimed?