Skip to content

Instantly share code, notes, and snippets.

@designfrontier
Created June 2, 2016 17:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save designfrontier/919df59e6739246ca8ad3bcd7181d54f to your computer and use it in GitHub Desktop.
Save designfrontier/919df59e6739246ca8ad3bcd7181d54f to your computer and use it in GitHub Desktop.
writeln("setting up server...")
server := HttpServer clone do(
setPort(8090)
renderResponse := method(request, response,
list("path", "uri", "body") foreach(k,
v := request perform(k)
response body appendSeq(k .. ": " .. v .. "<br>")
)
response body appendSeq("<hr>")
request headers keys sort foreach(k,
v := request headers at(k)
response body appendSeq(k .. ": " .. v .. "<br>")
)
)
)
writeln("starting server...")
server start
@designfrontier
Copy link
Author

For anyone finding this in the future... got it working by spinning it up in a docker container. This one to be specific: https://hub.docker.com/r/nacyot/io-io/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment