Created
September 19, 2012 04:40
-
-
Save andrewmp1/3747713 to your computer and use it in GitHub Desktop.
config.ru for ember rack app
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 'rake-pipeline' | |
require 'rake-pipeline/middleware' | |
use Rake::Pipeline::Middleware, 'Assetfile' | |
# require 'rack/streaming_proxy' | |
# use Rack::StreamingProxy do |request| | |
# if request.path.start_with?('/proxy') | |
# path = request.path | |
# if request.query_string | |
# path = "#{path}?#{request.query_string}" | |
# end | |
# "http://127.0.0.1:8080#{path}" | |
# end | |
# end | |
require 'rack-rewrite' | |
use Rack::Rewrite do | |
rewrite %r{^(.*)\/$}, '$1/index.html' | |
end | |
run Rack::Directory.new('.') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment