Skip to content

Instantly share code, notes, and snippets.

@kijuky
Last active March 13, 2016 15:31
Show Gist options
  • Select an option

  • Save kijuky/eaa697f05caa5b3fb493 to your computer and use it in GitHub Desktop.

Select an option

Save kijuky/eaa697f05caa5b3fb493 to your computer and use it in GitHub Desktop.
CGIでScalaを実行します。
#!/bin/sh
exec /usr/local/bin/scala "$0" "$@"
!#
import System._
println("Content-Type: text/html; charset=UTF-8\r\n\r\n")
println("<html>")
println("REQUEST_METHOD:" + getenv("REQUEST_METHOD"))
println("<br/>")
println("SCRIPT_NAME:" + getenv("SCRIPT_NAME"))
println("</html>")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment