Skip to content

Commit

Permalink
Split long lines to avoid horizontal scrolling
Browse files Browse the repository at this point in the history
  • Loading branch information
andreiltd committed Nov 13, 2024
1 parent caa3cc5 commit b2f1c47
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions crates/containerd-shim-wasmtime/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ Alternatively, you can use the pre-built [Hello World][5] example from this repo
Use `oci-tar-builder` to create an OCI image with our `http-handler`. Assuming our Wasm component is named `wasi-http.wasm`:

```shell
cargo run --bin oci-tar-builder -- --name wasi-http --repo ghcr.io/containerd/runwasi --tag latest --module wasi-http.wasm -o ./dist/wasi-http-img-oci.tar
cargo run --bin oci-tar-builder -- \
--name wasi-http \
--repo ghcr.io/containerd/runwasi \
--tag latest --module wasi-http.wasm \
-o ./dist/wasi-http-img-oci.tar
```

- Import the image:
Expand All @@ -62,7 +66,8 @@ sudo ctr image import --all-platforms ./dist/wasi-http-img-oci.tar
- Run the image:

```shell
sudo ctr run --rm --net-host --runtime=io.containerd.wasmtime.v1 ghcr.io/containerd/runwasi/wasi-js:latest wasi-http /wasi-http.wasm
sudo ctr run --rm --net-host --runtime=io.containerd.wasmtime.v1 \
ghcr.io/containerd/runwasi/wasi-js:latest wasi-http /wasi-http.wasm
```

- Finally, assuming our handler will respond to `GET` requests at `/`, we can
Expand Down

0 comments on commit b2f1c47

Please sign in to comment.