Currently, containerd-shim-wasmtime-v1 doesn't seem to be able to configure the underlying wasmtime runtime.
|
// Disable Wasmtime parallel compilation for the tests |
|
// see https://github.com/containerd/runwasi/pull/405#issuecomment-1928468714 for details |
|
config.parallel_compilation(!cfg!(test)); |
|
config.wasm_component_model(true); // enable component linking |
|
config.async_support(true); // must be on |
|
|
|
if use_pooling_allocator_by_default() { |
|
let cfg = wasmtime::PoolingAllocationConfig::default(); |
|
config.allocation_strategy(wasmtime::InstanceAllocationStrategy::Pooling(cfg)); |
|
} |
|
|
|
Self { |
|
engine: wasmtime::Engine::new(&config) |
|
.context("failed to create wasmtime engine") |
|
.unwrap(), |
|
cancel: CancellationToken::new(), |
This limitation prevent us from running our Wasm OCI artifact, built from component binary that requires -W function-references,gc unable to run on the shim. (on k8s, it ends up with CrashLoopBackOff).
https://github.com/users/tanishiking/packages/container/package/scala-wasm-echo-server (Wasm OCI artifact built by wkg oci push from Wasm component binary that implements wasi:http/proxy)
https://github.com/scala-wasm/scala-wasm/tree/scala-wasm/examples/echo-server
Is there a way to configure wasmtime from runwasi?
Currently,
containerd-shim-wasmtime-v1doesn't seem to be able to configure the underlying wasmtime runtime.runwasi/crates/containerd-shim-wasmtime/src/instance.rs
Lines 67 to 82 in 7a9c892
This limitation prevent us from running our Wasm OCI artifact, built from component binary that requires
-W function-references,gcunable to run on the shim. (on k8s, it ends up withCrashLoopBackOff).https://github.com/users/tanishiking/packages/container/package/scala-wasm-echo-server (Wasm OCI artifact built by
wkg oci pushfrom Wasm component binary that implementswasi:http/proxy)https://github.com/scala-wasm/scala-wasm/tree/scala-wasm/examples/echo-server
Is there a way to configure wasmtime from
runwasi?