로컬 컴퓨터에 설치가 제대로되어 있지만 heroku에서 동일한 작업을 수행 할 수 없습니다. 내가 만든 한Heroku에서 Firefly (ruby link shortener) 2.0을 설정 하시겠습니까?
유일한 변경 : Gemfile 다른 DBS를
- 변경 호스트 이름 만 주석 페이지
내 REPO에서 : https://github.com/hayksaakian/rxlcc
GitHub의 변경 내역 : https://github.com/hayksaakian/rxlcc/commit/d2e2f926b228372a9ff7861e918bdf193a3c3bca
,363,210내가 추측하고있어 생산 DB에는 연결이 없기 때문에입니다,하지만 난 그들에게
2012-12-31T05:36:20+00:00 heroku[web.1]: Starting process with command `bundle exec rackup config.ru -p 36424`
2012-12-31T05:36:26+00:00 app[web.1]: /usr/local/lib/ruby/1.9.1/syck.rb:135:in `load': syntax error on line 27, col 0: `adapter = uri.scheme' (ArgumentError)
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:236:in `load_dependency'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `require'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/config.ru:2:in `block in <main>'
2012-12-31T05:36:26+00:00 app[web.1]: from /usr/local/lib/ruby/1.9.1/syck.rb:135:in `load'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/lib/firefly/database.rb:8:in `config'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/lib/firefly/database.rb:13:in `<top (required)>'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/lib/firefly/database.rb:4:in `connect!'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `require'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `block in require'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:137:in `start'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/bin/rackup:4:in `<top (required)>'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/config.ru:1:in `new'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/bin/rackup:19:in `<main>'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:40:in `eval'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/lib/firefly.rb:30:in `<top (required)>'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/config.ru:1:in `<main>'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/config.ru:2:in `require'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:252:in `start'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:301:in `wrapped_app'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:200:in `app'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/bin/rackup:19:in `load'
2012-12-31T05:36:26+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:40:in `parse_file'
2012-12-31T05:36:28+00:00 heroku[web.1]: Process exited with status 1
2012-12-31T05:36:28+00:00 heroku[web.1]: State changed from starting to crashed
2012-12-31T05:41:04+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=rxlcc.herokuapp.com fwd=71.212.33.130 dyno= queue= wait= connect= service= status=503 bytes=
2012-12-31T05:41:05+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/favicon.ico host=rxlcc.herokuapp.com fwd=71.212.33.130 dyno= queue= wait= connect= service= status=503 bytes=
내 Heroku가 애드온 추가 할 경우 내가 확실 해요 :
heroku-postgresql:dev HEROKU_POSTGRESQL_NAVY
업데이트 :
나는/개똥 벌레/server.rb]로 LIB의 라인을 추가하는 시도# suggested by iain on stackoverflow
@config[:database_url] = ENV["DATABASE_URL"]
이
https://github.com/hayksaakian/rxlcc/commit/638bb8b215cf09f7edbafc0f21e964dfc05f86f2
2013-01-02T06:32:19+00:00 heroku[web.1]: State changed from crashed to starting
2013-01-02T06:32:22+00:00 heroku[web.1]: Starting process with command `bundle exec rackup config.ru -p 18667`
2013-01-02T06:32:25+00:00 app[web.1]: /usr/local/lib/ruby/1.9.1/syck.rb:135:in `load': syntax error on line 27, col 0: `adapter = uri.scheme' (ArgumentError)
2013-01-02T06:32:25+00:00 app[web.1]: from /usr/local/lib/ruby/1.9.1/syck.rb:135:in `load'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/lib/firefly/database.rb:8:in `config'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/lib/firefly/database.rb:4:in `connect!'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/lib/firefly/database.rb:13:in `<top (required)>'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `require'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `block in require'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:236:in `load_dependency'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251:in `require'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/lib/firefly.rb:30:in `<top (required)>'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/config.ru:2:in `require'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/config.ru:2:in `block in <main>'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/config.ru:1:in `new'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/config.ru:1:in `<main>'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:40:in `eval'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:40:in `parse_file'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:200:in `app'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:301:in `wrapped_app'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:252:in `start'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/server.rb:137:in `start'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.1/bin/rackup:4:in `<top (required)>'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/bin/rackup:19:in `load'
2013-01-02T06:32:25+00:00 app[web.1]: from /app/vendor/bundle/ruby/1.9.1/bin/rackup:19:in `<main>'
2013-01-02T06:32:26+00:00 heroku[web.1]: Process exited with status 1
2013-01-02T06:32:27+00:00 heroku[web.1]: State changed from starting to crashed
2013-01-02T06:37:44+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=rxlcc.herokuapp.com fwd=71.212.33.130 dyno= queue= wait= connect= service= status=503 bytes=
2013-01-02T06:37:44+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/favicon.ico host=rxlcc.herokuapp.com fwd=71.212.33.130 dyno= queue= wait= connect= service= status=503 bytes=
또한 firefly.yml의 호스트 이름 변수가 데이터베이스가 아닌 공개 도메인을 가리켜 야한다고 생각합니다. –
예, firefly.yml의 'hostname'은 공개 도메인 URL입니다. 'host'는 database.yml이 데이터베이스 서버를 가리켜 야합니다.예제에서 이것은 localhost로 간주되지만, 거의 그렇지 않을 것입니다. 'heroku config'를 실행하고 HEROKU_POSTGRESQL_NAVY_URL의 값을 얻은 다음 DATABASE_URL로 추가하면 거기에 포트가 없어도 쉽게 포트 할 수 있습니다. DATABASE_URL이 없으면 모든 앱에서이 작업을 수행합니다. – iain
도움을 주셔서 감사합니다. 반딧불 개발자와 이야기를 나눈 후에, 아직 생산을 위해 준비가되어 있지 않은 것 같습니다. 지금 https://github.com/ariejan/firefly-heroku를 사용하고 있습니다. –