#!/usr/bin/env wsapi.cgi local _M = {} function _M.run(wsapi_env) local headers = { ["Content-type"] = "text/html" } local function hello_text() coroutine.yield("") coroutine.yield("

Hello Wsapi!

") coroutine.yield("

PATH_INFO: " .. wsapi_env.PATH_INFO .. "

") coroutine.yield("

SCRIPT_NAME: " .. wsapi_env.SCRIPT_NAME .. "

") coroutine.yield("") end return 200, headers, coroutine.wrap(hello_text) end return _M