Commit 7364e67b authored by John E. Vincent's avatar John E. Vincent

Fixes for jruby/warbler. Hardcode some deps

parent 5e968b3d
......@@ -8,3 +8,5 @@ logs/*
*.class
tmp/*
*.war
.bundle
warbler/*
......@@ -3,12 +3,16 @@ PATH
specs:
noah (0.0.5)
haml (= 3.0.25)
nest (= 1.1.0)
ohm (= 0.1.3)
ohm-contrib (= 0.1.0)
ohm-contrib (= 0.1.1)
rack (= 1.2.1)
rake (= 0.8.7)
redis (= 2.1.1)
sinatra (= 1.1.2)
sinatra-namespace (= 0.6.1)
thin (= 1.2.7)
tilt (= 1.2.1)
vegas (= 0.1.8)
yajl-ruby (= 0.7.9)
......@@ -30,13 +34,14 @@ GEM
redis (~> 2.1)
ohm (0.1.3)
nest (~> 1.0)
ohm-contrib (0.1.0)
ohm-contrib (0.1.1)
ohm
rack (1.2.1)
rack-test (0.5.7)
rack (>= 1.0)
rake (0.8.7)
rcov (0.9.9)
rcov (0.9.9-java)
redis (2.1.1)
rspec (2.4.0)
rspec-core (~> 2.4.0)
......@@ -65,7 +70,7 @@ GEM
daemons (>= 1.0.9)
eventmachine (>= 0.12.6)
rack (>= 1.0.0)
tilt (1.2.2)
tilt (1.2.1)
vegas (0.1.8)
rack (>= 1.0.0)
yajl-ruby (0.7.9)
......
require 'bundler'
begin
Bundler.setup(:default, :development)
rescue Bundler::BundlerError => e
$stderr.puts e.message
$stderr.puts "Run `bundle install` to install missing gems"
exit e.status_code
end
#begin
# Bundler.setup(:default, :development)
#rescue Bundler::BundlerError => e
# $stderr.puts e.message
# $stderr.puts "Run `bundle install` to install missing gems"
# exit e.status_code
#end
require 'rake'
require 'rspec/core'
......@@ -103,3 +103,4 @@ RSpec::Core::RakeTask.new(:coverage) do |t|
t.verbose = true
t.rcov_opts = %q[--aggregate coverage.data --sort coverage --text-report --exclude "config,.bundle/*,gems/*,spec/*" -o doc/coverage -Ilib -i "noah.rb"]
end
require 'rubygems'
require 'sinatra'
require File.join(File.dirname(__FILE__), 'lib','noah')
ENV['REDIS_URL'] = "redis://localhost:6379/0"
require File.join('.', 'lib','noah')
## Uncomment the following to hardcode a redis url
#ENV['REDIS_URL'] = "redis://localhost:6379/0"
noah = Noah::App.new do
set :run, false
set :environment, :production
set :server, %w[thin mongrel webrick Jetty Kirk]
## Set your server list up here
# set :server, %w[thin mongrel webrick Jetty Kirk]
end
run noah
......@@ -4,14 +4,15 @@
# Warbler web application assembly configuration file
Warbler::Config.new do |config|
#config.features = %w(gemjar)
config.dirs = %w(bin config lib views)
config.dirs = %w(config lib views)
config.includes = FileList["config.ru"]
#config.bundler = false
config.gems += ["ohm", "ohm-contrib", "sinatra", "sinatra-namespace", "haml", "vegas"]
config.excludes = FileList["noah.gemspec", "Gemfile", "Gemfile.lock"]
config.bundler = false
config.gems += ["json", "ohm", "ohm-contrib", "sinatra", "sinatra-namespace", "haml"]
config.gem_excludes = [/^(test|spec)\//]
config.public_html = FileList["views/**/*"]
config.webxml.booter = :rack
config.webxml.rackup.path = 'WEB-INF/config.ru'
#config.webxml.rackup.path = 'WEB-INF/config.ru'
#config.webxml.rackup = %{require './lib/noah'; run Noah::App}
# config.webxml.rackup = require 'cgi' && CGI::escapeHTML(File.read("config.ru"))
end
......@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
s.require_paths = ["lib"]
s.add_dependency("redis", ["= 2.2.1"])
s.add_dependency("redis", ["= 2.1.1"])
s.add_dependency("nest", ["= 1.1.0"])
s.add_dependency("rack", ["= 1.2.1"])
s.add_dependency("rake", ["= 0.8.7"])
......
......@@ -8,42 +8,42 @@
%h2 Hosts
%ul
%li
%a{:href => "/h/"} All registered Hosts
%a{:href => "h/"} All registered Hosts
%li
%a{:href => "/h/localhost"} localhost (this server)
%a{:href => "h/localhost"} localhost (this server)
%li
%a{:href => "/h/localhost/noah"} localhost noah service
%a{:href => "h/localhost/noah"} localhost noah service
#header
%h2 Services
%ul
%li
%a{:href => "/s/"} All registered Services
%a{:href => "s/"} All registered Services
%li
%a{:href => "/s/http"} All hosts providing 'http'
%a{:href => "s/http"} All hosts providing 'http'
%li
%a{:href => "/s/noah/localhost"} localhost noah service
%a{:href => "s/noah/localhost"} localhost noah service
#header
%h2 Applications
%ul
%li
%a{:href => "/a/"} All registered Applications
%a{:href => "a/"} All registered Applications
%li
%a{:href => "/a/noah"} Noah Application entry
%a{:href => "a/noah"} Noah Application entry
%li
%a{:href => "/a/noah/redis"} Noah Redis configuration entry
%a{:href => "a/noah/redis"} Noah Redis configuration entry
#header
%h2 Configurations
%ul
%li
%a{:href => "/c/"} All registered Configurations
%a{:href => "c/"} All registered Configurations
%li
%a{:href => "/c/noah"} Noah Configuration entry
%a{:href => "c/noah"} Noah Configuration entry
%li
%a{:href => "/c/myrailsapp1"} myrailsapp1 Configuration entry
%a{:href => "c/myrailsapp1"} myrailsapp1 Configuration entry
%li
%a{:href => "/c/myrestapp1"} myrestapp1 Configuration entry
%a{:href => "c/myrestapp1"} myrestapp1 Configuration entry
%li
%a{:href => "/c/myrailsapp1/database.yml"} database.yml file for myrailsapp1 (should return the proper content-type)
%a{:href => "c/myrailsapp1/database.yml"} database.yml file for myrailsapp1 (should return the proper content-type)
%li
%a{:href => "/c/myrestapp1/config.json"} config.json file for myrestapp1
%a{:href => "c/myrestapp1/config.json"} config.json file for myrestapp1
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment