Created
January 25, 2010 20:54
-
-
Save rmanalan/286233 to your computer and use it in GitHub Desktop.
Static websites using Heroku
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rack-contrib | |
rack-rewrite |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "rubygems" | |
require 'rack/contrib' | |
require 'rack-rewrite' | |
use Rack::Static, :urls => ['/images'], :root => "public" | |
use Rack::ETag | |
use Rack::Rewrite do | |
rewrite '/', '/index.html' | |
end | |
run Rack::Directory.new('public') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment