前提・実現したいこと
rails g devise:installを実行したいです。
発生している問題
rails g devise:installを実行するとエラーが発生する。
エラーメッセージ
Traceback (most recent call last): 38: from bin/rails:4:in `<main>' 37: from bin/rails:4:in `require' 36: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/commands.rb:18:in `<top (required)>' 35: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/command.rb:46:in `invoke' 34: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/command/base.rb:69:in `perform' 33: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor.rb:392:in `dispatch' 32: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command' 31: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run' 30: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/commands/generate/generate_command.rb:21:in `perform' 29: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/command/actions.rb:14:in `require_application_and_environment!' 28: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/command/actions.rb:22:in `require_application!' 27: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-6.0.3.1/lib/rails/command/actions.rb:22:in `require' 26: from C:/Users/r1148/butube/config/application.rb:3:in `<top (required)>' 25: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler.rb:174:in `require' 24: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:58:in `require' 23: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:58:in `each' 22: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:69:in `block in require' 21: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:69:in `each' 20: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:74:in `block (2 levels) in require' 19: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/bundler-2.1.4/lib/bundler/runtime.rb:74:in `require' 18: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/coffee-rails-5.0.0/lib/coffee-rails.rb:1:in `<top (required)>' 17: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 16: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:291:in `load_dependency' 15: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `block in require' 14: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 13: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/coffee-script-2.4.1/lib/coffee-script.rb:1:in `<top (required)>' 12: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 11: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:291:in `load_dependency' 10: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `block in require' 9: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 8: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/coffee-script-2.4.1/lib/coffee_script.rb:1:in `<top (required)>' 7: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 6: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:291:in `load_dependency' 5: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `block in require' 4: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/activesupport-6.0.3.1/lib/active_support/dependencies.rb:324:in `require' 3: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/execjs-2.7.0/lib/execjs.rb:4:in `<top (required)>' 2: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/execjs-2.7.0/lib/execjs.rb:5:in `<module:ExecJS>' 1: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb:57:in `autodetect' C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb:71:in `from_environment': Node.js (V8) runtime is not available on this system (ExecJS::RuntimeUnavailable)
該当のソースコード
Gemfile
source 'https://rubygems.org' git_source(:github) { |repo| "https://github.com/#{repo}.git" } ruby '2.6.6' gem 'rails', '~> 6.0.3', '>= 6.0.3.1' gem 'pg', '>= 0.18', '< 2.0' gem 'puma', '~> 4.1' gem 'sass-rails', '>= 6' gem 'webpacker', '~> 4.0' gem 'turbolinks', '~> 5' group :development do gem 'web-console', '>= 3.3.0' end gem 'tzinfo-data' gem 'safe_attributes', '~> 1.0', '>= 1.0.10' gem 'coffee-rails', '~> 5.0.0' gem 'webdriver' gem 'selenium-webdriver' gem "nokogiri", ">= 1.10.8" gem 'rails-i18n' gem 'bootstrap', '~> 4.1.1' gem 'bcrypt' gem 'devise-i18n' gem 'jquery-ui-rails' gem 'jquery-rails', '~> 4.4' gem 'rails_12factor' gem 'devise'
補足情報
Windows 10 home 64ビット
ruby 2.6.6
Ruby on rails 6.0.3.1
PostgreSQL 13beta1
テキストエディタ Atom
失礼な点があるかもしれませんがどうぞ宜しくおねがい致します。
Node.jsはインストールしていますか?
Node.jsをアンインストールしていたのを忘れていたので入れ直しました。
次に「C:/Ruby26-x64/lib/ruby/2.6.0/ipaddr.rb:598:in `rescue in initialize': invalid address:http://localhost:3000 (IPAddr::InvalidAddressError)」というエラーが出てしまいました。
回答1件
あなたの回答
tips
プレビュー