2017-04-24 9 views
0

私はOdinプロジェクトのカリキュラムを使い、Ubuntuを使い始めました。Installfests guide on deploying a Rails App.にはステップ2.5で問題があります。私も更新しようとした新しいユーザーのデプロイメントの失敗

group :development, :test do 
    gem 'sqlite3' 
end 

group :production do 
    gem 'pg' 
end 

:で

gem 'sqlite3' 

:私はそのような私の宝石のファイル交換を編集するなど、さまざまなものを試してみました

$ git push heroku master 
Counting objects: 117, done. 
Delta compression using up to 4 threads. 
Compressing objects: 100% (103/103), done. 
Writing objects: 100% (117/117), 25.89 KiB | 0 bytes/s, done. 
Total 117 (delta 8), reused 0 (delta 0) 
remote: Compressing source files... done. 
remote: Building source: 
remote: 
remote: -----> Ruby app detected 
remote: -----> Compiling Ruby/Rails 
remote: -----> Using Ruby version: ruby-2.3.4 
remote: -----> Installing dependencies using bundler 1.13.7 
remote:  Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment 
remote:  Warning: the running version of Bundler (1.13.7) is older than the version that created the lockfile (1.14.6). We suggest you upgrade to the latest version of Bundler by running `gem install bundler`. 
remote:  Fetching gem metadata from https://rubygems.org/......... 
remote:  Fetching version metadata from https://rubygems.org/.. 
remote:  Fetching dependency metadata from https://rubygems.org/. 
remote:  Installing rake 12.0.0 
remote:  Installing i18n 0.8.1 
remote:  Installing concurrent-ruby 1.0.5 
remote:  Installing minitest 5.10.1 
remote:  Installing thread_safe 0.3.6 
remote:  Installing builder 3.2.3 
remote:  Installing erubis 2.7.0 
remote:  Installing mini_portile2 2.1.0 
remote:  Installing nio4r 2.0.0 with native extensions 
remote:  Installing rack 2.0.1 
remote:  Installing websocket-extensions 0.1.2 
remote:  Installing arel 7.1.4 
remote:  Installing mime-types-data 3.2016.0521 
remote:  Installing coffee-script-source 1.12.2 
remote:  Installing execjs 2.7.0 
remote:  Installing thor 0.19.4 
remote:  Installing method_source 0.8.2 
remote:  Installing multi_json 1.12.1 
remote:  Installing pg 0.20.0 with native extensions 
remote:  Installing puma 3.8.2 with native extensions 
remote:  Using bundler 1.13.7 
remote:  Installing sass 3.4.23 
remote:  Installing tilt 2.0.7 
remote:  Installing turbolinks-source 5.0.0 
remote:  Installing tzinfo 1.2.3 
remote:  Installing nokogiri 1.7.1 with native extensions 
remote:  Installing rack-test 0.6.3 
remote:  Installing sprockets 3.7.1 
remote:  Installing websocket-driver 0.6.5 with native extensions 
remote:  Installing mime-types 3.1 
remote:  Installing coffee-script 2.4.1 
remote:  Installing uglifier 3.2.0 
remote:  Installing turbolinks 5.0.1 
remote:  Installing activesupport 5.0.2 
remote:  Installing mail 2.6.4 
remote:  Installing globalid 0.4.0 
remote:  Installing activemodel 5.0.2 
remote:  Installing jbuilder 2.6.3 
remote:  Installing activejob 5.0.2 
remote:  Installing activerecord 5.0.2 
remote:  Installing rails-dom-testing 2.0.2 
remote:  Installing loofah 2.0.3 
remote:  Installing rails-html-sanitizer 1.0.3 
remote:  Installing actionview 5.0.2 
remote:  Installing actionpack 5.0.2 
remote:  Installing actioncable 5.0.2 
remote:  Installing actionmailer 5.0.2 
remote:  Installing railties 5.0.2 
remote:  Installing sprockets-rails 3.2.0 
remote:  Installing rails 5.0.2 
remote:  Installing coffee-rails 4.2.1 
remote:  Installing sass-rails 5.0.6 
remote:  Installing jquery-rails 4.3.1 
remote:  Bundle complete! 16 Gemfile dependencies, 53 gems now installed. 
remote:  Gems in the groups development and test were not installed. 
remote:  Bundled gems are installed into ./vendor/bundle. 
remote:  Bundle completed (26.35s) 
remote:  Cleaning up the bundler cache. 
remote: -----> Installing node-v6.10.0-linux-x64 
remote: -----> Detecting rake tasks 
remote: -----> Preparing app for Rails asset pipeline 
remote:  Running: rake assets:precompile 
remote:  rake aborted! 
remote:  NoMethodError: undefined method `roots' for #<ActionDispatch::Routing::Mapper:0x007fc37aff5b28> 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/config/routes.rb:2:in `block in <top (required)>' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.2/lib/action_dispatch/routing/route_set.rb:389:in `instance_exec' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.2/lib/action_dispatch/routing/route_set.rb:389:in `eval_block' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.2/lib/action_dispatch/routing/route_set.rb:371:in `draw' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/config/routes.rb:1:in `<top (required)>' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.2/lib/active_support/dependencies.rb:287:in `load' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.2/lib/active_support/dependencies.rb:287:in `block in load' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.2/lib/active_support/dependencies.rb:259:in `load_dependency' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.2/lib/active_support/dependencies.rb:287:in `load' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:40:in `block in load_paths' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:40:in `each' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:40:in `load_paths' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:16:in `reload!' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:26:in `block in updater' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/activesupport-5.0.2/lib/active_support/file_update_checker.rb:77:in `execute' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:27:in `updater' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application/finisher.rb:119:in `block in <module:Finisher>' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/initializable.rb:30:in `instance_exec' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/initializable.rb:30:in `run' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/initializable.rb:55:in `block in run_initializers' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/initializable.rb:54:in `run_initializers' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application.rb:352:in `initialize!' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/config/environment.rb:5:in `<top (required)>' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application.rb:328:in `require' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application.rb:328:in `require_environment!' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/railties-5.0.2/lib/rails/application.rb:448:in `block in run_tasks_blocks' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/sprockets-rails-3.2.0/lib/sprockets/rails/task.rb:62:in `block (2 levels) in define' 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/vendor/bundle/ruby/2.3.0/gems/rake-12.0.0/exe/rake:27:in `<top (required)>' 
remote:  Tasks: TOP => environment 
remote:  (See full trace by running task with --trace) 
remote: ! 
remote: !  Precompiling assets failed. 
remote: ! 
remote: !  Push rejected, failed to compile Ruby app. 
remote: 
remote: !  Push failed 
remote: Verifying deploy... 
remote: 
remote: ! Push rejected to evening-harbor-57945. 
remote: 
To https://git.heroku.com/evening-harbor-57945.git 
! [remote rejected] master -> master (pre-receive hook declined) 
error: failed to push some refs to 'https://git.heroku.com/evening-harbor-57945.git' 

:ここ

は私が得る結果であり、私のgit push heroku masterからのフィードバックに記載されているgemfileは、次のように入力します:

gem install bundler 

でも同じ結果が得られます。

+0

「スマートウェイの質問方法(http://catb.org/esr/faqs/smart-questions.html)」の全文を読むことをお勧めします。私たちはあなたの経験が何であるか気にせず、よく研究され、よく尋ねられる質問がほしいだけです。 「[尋ねる]」と「[mcve]」は重要です。「[Stack Overflowユーザーにはどの程度の研究努力が必要ですか?](http://meta.stackoverflow.com/questions/261592)」問題を直接説明していない質問からすべてを削除します。特に謝罪してください。それを簡潔かつ明確にしてください。あなたの質問は、百科事典の新しいエントリーを開くことです。そのように書いてください。 –

+0

フィードバックに感謝します。ジェリーは私を正しい方向に戻してくれました。私は将来私の言い回しにも気を配ります。 – vandudemeister

答えて

1

はあなたのログを確認し、エラーを見つける:config/routes.rb:2:あなたが慎重に読めば

remote:  NoMethodError: undefined method `roots' for #<ActionDispatch::Routing::Mapper:0x007fc37aff5b28> 
remote:  /tmp/build_e6fc23c1f302b4f1aa2bdeafdf93c2f5/config/routes.rb:2:in `block in <top (required)>' 

は、ファイルと、エラーが生成された行番号を見つけます。それから、

私は、あなたがステップ 2.3roots代わりの rootを使用することを config/routes.rbので、オープンを想定し、あなたがこれを持っていることを確認:あなたの問題を解決する必要があり

root 'drinks#index' 

関連する問題