Created
June 10, 2011 02:51
-
-
Save napcs/1018160 to your computer and use it in GitHub Desktop.
warbler + sinatra problem
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
reproducable warbler issue. Change the public directory in lib/server.rb to someplace with jquery.min.js in it and serve it. | |
Under JRuby with | |
rackup config.ru | |
everything works great. | |
But with | |
jruby -S warble executable war | |
and then running with java -jar warname.war | |
when I visit http://localhost:8080/jquery.min.js | |
It truncates for me with safari, ff, chrome, and curl. I'm extremely lost. |
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 'lib/server' | |
set :run, false | |
run Sinatra::Application | |
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
source :rubygems | |
gem 'sinatra', '1.2.3' | |
gem 'tilt', "1.3" | |
gem 'rack', "1.2.2" | |
gem 'sinatra-respond_to', '0.7.0' |
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
## THIS MUST BE IN lib/server.rb BUT GIST WON'T LET ME PUT IT THERE! | |
require 'bundler/setup' | |
require 'fileutils' | |
require 'sinatra' | |
#Sinatra::Application.register Sinatra::RespondTo | |
set :public, "/Users/brianhogan/oss/files" | |
get "/" do | |
puts "hai there." | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment