diff --git a/pages/edge/tutorials/wcgi-on-edge.mdx b/pages/edge/tutorials/wcgi-on-edge.mdx index b1645fb..a12905b 100644 --- a/pages/edge/tutorials/wcgi-on-edge.mdx +++ b/pages/edge/tutorials/wcgi-on-edge.mdx @@ -91,9 +91,13 @@ fn handler(request: Request) -> Response { ### Wiring it up with WCGI -We'll use the `wcgi` runner from Wasmer to run our CGI app. -This wiring up is done automatically by the wasmer runtime and we just need to specify -the runner. +Let's create a `wasmer.toml` file in the root of the project. For integrating with WCGI, +we'll use the `wcgi` runner from Wasmer to run our CGI app.This wiring up is done +automatically by the wasmer runtime and we just need to specify the runner. + +```bash +touch wasmer.toml +``` ```toml copy filename="Cargo.toml" [package] @@ -158,12 +162,14 @@ To test the app, we can use `curl` to send a request to the server. curl http://localhost:8000 ``` -The root path will return `Hello, World!` as we didn't specify any name in the body. - ```console Hello, World! ``` +The root path will return `Hello, World!` as we didn't specify any name in the body. + +We can also send a `POST` request with a body to the server. + ```bash copy curl -X POST -d "Wasmer" http://localhost:8000 ``` @@ -230,6 +236,20 @@ New version is now reachable at https://wasmer-wcgi-rust-template.wasmer.app Deployment complete ``` + + And now you can view your Static files at the URL mentioned above. You can + also view the admin dashboard of your CDN by visiting the URL mentioned above. + + + + You'll need to do `wasmer deploy` again if you add any new files to the + `public` directory. + + + + The url of your project will be different from the one mentioned above. + + ### Testing the deployed app We can test the deployed app using `curl`.