{"id":15776524,"url":"https://github.com/devigned/wasi-worker","last_synced_at":"2026-03-18T03:58:23.206Z","repository":{"id":164136415,"uuid":"639497497","full_name":"devigned/wasi-worker","owner":"devigned","description":null,"archived":false,"fork":false,"pushed_at":"2023-05-12T12:07:53.000Z","size":134,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-10-05T17:22:02.112Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Makefile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devigned.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-11T15:14:12.000Z","updated_at":"2023-05-12T06:30:19.000Z","dependencies_parsed_at":"2023-06-02T02:15:05.957Z","dependency_job_id":null,"html_url":"https://github.com/devigned/wasi-worker","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/devigned/wasi-worker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devigned%2Fwasi-worker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devigned%2Fwasi-worker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devigned%2Fwasi-worker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devigned%2Fwasi-worker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devigned","download_url":"https://codeload.github.com/devigned/wasi-worker/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devigned%2Fwasi-worker/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30646441,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-18T02:48:56.676Z","status":"ssl_error","status_checked_at":"2026-03-18T02:48:55.747Z","response_time":104,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-04T17:22:10.132Z","updated_at":"2026-03-18T03:58:23.188Z","avatar_url":"https://github.com/devigned.png","language":"Makefile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# wasi-worker\n\nJust a super simple illustration of WASI being used locally with Wasmtime and Wrangler, as well as being deployed to CloudFlare.\n\n## Required Tools\n- [Cargo](https://rustup.rs)\n- [npx](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm)\n- [wasmtime](https://docs.wasmtime.dev/cli-install.html)\n- [wrangler](https://developers.cloudflare.com/workers/wrangler/)\n- make\n\n## What Can the Makefile Do?\n```shell\n$ make\n\nUsage:\n  make \u003ctarget\u003e\n  build                      Build the WASI worker module\n  run-cf                     Run the WASI worker module with CloudFlare Wrangler\n  run-wt                     Run the WASI worker module with Wasmtime\n  publish-cf                 Publish the WASI worker module to CloudFlare\n  help                       Display this help.\n```\n\n## Instructions for Running with Wasmtime\n\nBefore you begin, you need to make sure you have the `wasm32-wasi` target installed. To do this, run the following:\n```shell\n$ rustup target add wasm32-wasi\n```\n\nTo run the WASI worker using Wasmtime, run the following:\n```shell\n$ make run-wt\n```\nYou should see `Hello, world!` output from the worker.\n\nThe preceding command will build the Rust worker project, then run wasmtime. If you are curious, take a look at the Makefile.\n\n## Instructions for Running with CloudFlare's Wrangler\nTo run the WASI worker using CloudFlare's Wrangler, run the following:\n```shell\n$ make run-cf\n```\nYou should see something like the following output.\n\nPlease note that if you don't have `wrangler@wasm` installed, you will be prompted to install it. Please proceed with (y).\n\nIt may help to be previously logged in to CloudFlare. If you are not logged in, you will be prompted to login. Please proceed with (y).\n\nThe run\n```shell\n$ make run-cf\ncargo build --target wasm32-wasi --release\n    Finished release [optimized] target(s) in 0.00s\nnpx wrangler@wasm dev target/wasm32-wasi/release/worker.wasm\n ⛅️ wrangler 0.0.0-c0d7699\n---------------------------\n⬣ Listening at http://localhost:8787\nTotal Upload: 2228.94 KiB / gzip: 563.45 KiB\n```\n\nIf you open your browser to the URI above, `http://localhost:8787`, you should see `Hello, world!`.\n\n## Instructions for Publishing to CloudFlare\nTo publish your work to CloudFlare stop the server or open a new tab in your terminal, then run the following. If you had logged out of CloudFlare, you will be prompted to login again. Please proceed with (y) and follow instructions.\n\n```shell\n$ make publish-cf\n```\nYou should see something like the following output.\n```shell\n$ make publish-cf\ncargo build --target wasm32-wasi --release\n    Finished release [optimized] target(s) in 0.00s\nnpx wrangler@wasm publish --name wasi-worker --compatibility-date 2023-04-11 target/wasm32-wasi/release/worker.wasm\n ⛅️ wrangler 0.0.0-c0d7699\n---------------------------\nTotal Upload: 2228.94 KiB / gzip: 563.44 KiB\nUploaded wasi-worker (2.84 sec)\nPublished wasi-worker (3.76 sec)\n  wasi-worker.[your-CF-username].workers.dev\n```\nIf you open your CloudFlare portal, you should see something like the following.\n![CloudFlare WASI Worker](./imgs/cf-wasi-worker.png)\nIf you click on the `Preview` link, wasi-worker.[your-CF-username].workers.dev in the preceding image, you will be greeted with the `Hello, world!` you saw in preceding sections.\n\nPlease note that [your-CF-username] will be replaced with your CloudFlare username.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevigned%2Fwasi-worker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevigned%2Fwasi-worker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevigned%2Fwasi-worker/lists"}