Skip to content

Instantly share code, notes, and snippets.

@stubotnik
Created March 14, 2014 21:42
Show Gist options
  • Save stubotnik/9557599 to your computer and use it in GitHub Desktop.
Save stubotnik/9557599 to your computer and use it in GitHub Desktop.
simplest rack for static site (page)
use Rack::Static,
:urls => ["/img", "/js"],
:root => "public"
run lambda { |env|
[
200,
{ 'Content-Type' => 'text/html' },
File.open('public/index.html', File::RDONLY)
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment