2011-11-17 3 views
2

그래서, 저는이 사실을 정말로 압도합니다. 나는이 문제를 해결할 수 없다면 내 친구를 때려 눕힐거야 ... 그래서, 나는 Heroku에 Sinatra 응용 프로그램을 배포하려고하는데, 시도 할 때마다, 나는 동일한 오류 메시지를 얻는다. 오류". 그것은Heroku + Sinatra : H10 (응용 프로그램이 충돌 함)

$ruby sppin.rb 

을 실행하여, 그런데, 내 로컬 서버에서 원활하게 실행 여기 내 로그 내 config.ru 파일입니다 : (. 아이폰에 대한 유감 = /)

2011-11-17T18:14:47+00:00 heroku[api]: Deploy 438c175 by [email protected] 
2011-11-17T18:14:47+00:00 heroku[api]: Release v13 created by [email protected] 
2011-11-17T18:14:47+00:00 heroku[web.1]: State changed from created to starting 
2011-11-17T18:14:47+00:00 heroku[slugc]: Slug compilation finished 
2011-11-17T18:14:50+00:00 heroku[web.1]: Starting process with command `thin -p 19178 -e production -R /home/heroku_rack/heroku.ru start` 
2011-11-17T18:14:50+00:00 app[web.1]: <internal:lib/rubygems/custom_require>:29:in `require': no such file to load -- sppin (LoadError) 
2011-11-17T18:14:50+00:00 app[web.1]: from <internal:lib/rubygems/custom_require>:29:in `require' 
2011-11-17T18:14:50+00:00 app[web.1]: from config.ru:1:in `block (3 levels) in <main>' 
2 011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:23:in `eval' 
2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:23:in `block (3 levels) in <main>' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `instance_eval' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `initialize' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:63:in `new' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:63:in `map' 
2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:18:in `block (2 levels) in <main>' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `instance_eval' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `initialize' 
2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:11:in 

2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:11:in `block in <main>' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `instance_eval' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/rack-1.1.0/lib/rack/builder.rb:46:in `initialize' 
2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:1:in `new' 
2011-11-17T18:14:50+00:00 app[web.1]: from /home/heroku_rack/heroku.ru:1:in `<main>' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/rack/adapter/loader.rb:36:in `eval' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/rack/adapter/loader.rb:36:in `load' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/thin/controllers/controller.rb:175:in `load_rackup_config' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/thin/controllers/controller.rb:65:in `start' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/thin/runner.rb:177:in `run_command' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/lib/thin/runner.rb:143:in `run!' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/thin-1.2.6/bin/thin:6:in `<top (required)>' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/bin/thin:19:in `load' 
2011-11-17T18:14:50+00:00 app[web.1]: from /usr/ruby1.9.2/bin/thin:19:in `<main>' 
2011-11-17T18:14:50+00:00 heroku[web.1]: Process exited 
2011-11-17T18:14:51+00:00 heroku[web.1]: State changed from starting to crashed 
2011-11-17T18:14:52+00:00 heroku[router]: Error H10 (App crashed) -> GET freezing-sky-8753.heroku.com/ dyno= queue= wait= service= status=503 bytes= 
2011-11-17T18:14:52+00:00 heroku[nginx]: 150.164.3.247 - - [17/Nov/2011:10:14:52 -0800] "GET/HTTP/1.1" 503 607 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.2 (KHTML, like Gecko) Chrome/15.0.874.120 Safari/535.2" freezing-sky-8753.heroku.com 
2011-11-17T18:14:53+00:00 heroku[router]: Error H10 (App crashed) -> GET freezing-sky-8753.heroku.com/favicon.ico dyno= queue= wait= service= status=503 bytes= 
2011-11-17T18:14:53+00:00 heroku[nginx]: 150.164.3.247 - - [17/Nov/2011:10:14:53 -0800] "GET /favicon.ico HTTP/1.1" 503 607 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.2 (KHTML, like Gecko) Chrome/15.0.874.120 Safari/535.2" freezing-sky-8753.heroku.com 

config.ru :

require 'sppin' 
    run Sinatra::Application 

그리고, 단지 기록을 위해, 내 sppin.rb 파일 : (아주 기본적인 것들)

,
require 'rubygems' 
require 'sinatra' 
require 'haml' 

get '/' do 
    @title = "Sppin" 
    haml :index 
end 

답변

2

그냥 내 문제를 발견했습니다. 내 응용 프로그램에서 사용한 보석을 포함하여 응용 프로그램 루트에 .gems 파일을 추가해야했습니다. 내 경우에는 Sinatra와 Haml을 사용 했으므로 .gems 파일은 다음과 같습니다.

source 'http://rubygems.org' 
'sinatra' 
'haml' 
0

절대 경로를 사용하십시오 (귀하의 경우에 따라 조정하십시오).

require File.expand_path('../sppin', __FILE__) 
+0

아니요. 그러지 마라. –

관련 문제