pub fn detect_wasi_runability() -> Result<bool>
Expand description
Detect the ability to run WASI
This attempts to run a small embedded WASI program, and returns true if no errors happened.
Errors returned by the Result
are I/O errors from the establishment of the context, not
errors from the run attempt.
On Linux, you can configure your system to run WASI programs using a binfmt directive. Under
systemd, write the below to /etc/binfmt.d/wasi.conf
, with /usr/bin/wasmtime
optionally
replaced with the path to your WASI runtime of choice:
:wasi:M::\x00asm::/usr/bin/wasmtime: