質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.50%
Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

Ruby on Rails 6

Ruby on Rails 6は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

Q&A

解決済

1回答

976閲覧

Heroku デプロイ エラー

rrtts667

総合スコア18

Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

Ruby on Rails 6

Ruby on Rails 6は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

Heroku

HerokuはHeroku社が開発と運営を行っているPaaSの名称です。RubyやNode.js、Python、そしてJVMベース(Java、Scala、Clojureなど)の複数のプログラミング言語をサポートしている。

0グッド

0クリップ

投稿2020/09/02 03:35

Herokuでデプロイ中にエラーが出てしまいます。
おそらくwebpackが原因かと思いますがどのようにすればよろしいでしょうか?

Heroku

1 Compiling... 2 Compilation failed: 3 /tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js:93 4 throw err; 5 ^ 6 7 Error: Cannot find module 'vue-loader' 8 Require stack: 9 - /tmp/build_49d167b2_/config/webpack/environment.js 10 - /tmp/build_49d167b2_/config/webpack/production.js 11 - /tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js 12 - /tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js 13 - /tmp/build_49d167b2_/node_modules/webpack/bin/webpack.js 14 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:980:15) 15 at Function.Module._load (internal/modules/cjs/loader.js:862:27) 16 at Module.require (internal/modules/cjs/loader.js:1042:19) 17 at require (/tmp/build_49d167b2_/node_modules/v8-compile-cache/v8-compile-cache.js:161:20) 18 at Object.<anonymous> (/tmp/build_49d167b2_/config/webpack/environment.js:2:29) 19 at Module._compile (/tmp/build_49d167b2_/node_modules/v8-compile-cache/v8-compile-cache.js:194:30) 20 at Object.Module._extensions..js (internal/modules/cjs/loader.js:1176:10) 21 at Module.load (internal/modules/cjs/loader.js:1000:32) 22 at Function.Module._load (internal/modules/cjs/loader.js:899:14) 23 at Module.require (internal/modules/cjs/loader.js:1042:19) 24 at require (/tmp/build_49d167b2_/node_modules/v8-compile-cache/v8-compile-cache.js:161:20) 25 at Object.<anonymous> (/tmp/build_49d167b2_/config/webpack/production.js:3:21) 26 at Module._compile (/tmp/build_49d167b2_/node_modules/v8-compile-cache/v8-compile-cache.js:194:30) 27 at Object.Module._extensions..js (internal/modules/cjs/loader.js:1176:10) 28 at Module.load (internal/modules/cjs/loader.js:1000:32) 29 at Function.Module._load (internal/modules/cjs/loader.js:899:14) 30 at Module.require (internal/modules/cjs/loader.js:1042:19) 31 at require (/tmp/build_49d167b2_/node_modules/v8-compile-cache/v8-compile-cache.js:161:20) 32 at WEBPACK_OPTIONS (/tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js:114:13) 33 at requireConfig (/tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js:116:6) 34 at /tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js:123:17 35 at Array.forEach (<anonymous>) 36 at module.exports (/tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js:121:15) 37 at /tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js:71:45 38 at Object.parse (/tmp/build_49d167b2_/node_modules/yargs/yargs.js:576:18) 39 at /tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js:49:8 40 at Object.<anonymous> (/tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js:366:3) 41 at Module._compile (internal/modules/cjs/loader.js:1156:30) 42 at Object.Module._extensions..js (internal/modules/cjs/loader.js:1176:10) 43 at Module.load (internal/modules/cjs/loader.js:1000:32) 44 at Function.Module._load (internal/modules/cjs/loader.js:899:14) 45 at Module.require (internal/modules/cjs/loader.js:1042:19) 46 at require (internal/modules/cjs/helpers.js:77:18) 47 at Object.<anonymous> (/tmp/build_49d167b2_/node_modules/webpack/bin/webpack.js:156:2) 48 at Module._compile (internal/modules/cjs/loader.js:1156:30) 49 at Object.Module._extensions..js (internal/modules/cjs/loader.js:1176:10) { 50 code: 'MODULE_NOT_FOUND', 51 requireStack: [ 52 '/tmp/build_49d167b2_/config/webpack/environment.js', 53 '/tmp/build_49d167b2_/config/webpack/production.js', 54 '/tmp/build_49d167b2_/node_modules/webpack-cli/bin/utils/convert-argv.js', 55 '/tmp/build_49d167b2_/node_modules/webpack-cli/bin/cli.js', 56 '/tmp/build_49d167b2_/node_modules/webpack/bin/webpack.js' 57 ] 58 } 59 60 ! 61 ! Precompiling assets failed. 62 ! 63 ! Push rejected, failed to compile Ruby app. 64 ! Push failed

Gemfile

rails

1source 'https://rubygems.org' 2git_source(:github) { |repo| "https://github.com/#{repo}.git" } 3 4ruby '2.6.5' 5 6# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' 7gem 'rails', '~> 6.0.0' 8# Use mysql as the database for Active Record 9gem 'mysql2', '0.5.3' 10# Use Puma as the app server 11gem 'puma', '~> 3.11' 12# Use SCSS for stylesheets 13gem 'sass-rails', '~> 5' 14# Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker 15gem 'webpacker', '~> 4.0' 16# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks 17gem 'turbolinks', '~> 5' 18# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder 19gem 'jbuilder', '~> 2.7' 20# Use Redis adapter to run Action Cable in production 21# gem 'redis', '~> 4.0' 22# Use Active Model has_secure_password 23# gem 'bcrypt', '~> 3.1.7' 24 25# Use Active Storage variant 26# gem 'image_processing', '~> 1.2' 27 28# Reduces boot times through caching; required in config/boot.rb 29gem 'bootsnap', '>= 1.4.2', require: false 30 31group :development, :test do 32 # Call 'byebug' anywhere in the code to stop execution and get a debugger console 33 gem 'byebug', platforms: [:mri, :mingw, :x64_mingw] 34 gem 'sqlite3' #do ~ end内部に追加。他のgemは残してください。 35end 36 37group :development do 38 # Access an interactive console on exception pages or by calling 'console' anywhere in the code. 39 gem 'web-console', '>= 3.3.0' 40 gem 'listen', '>= 3.0.5', '< 3.2' 41 # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring 42 gem 'spring' 43 gem 'spring-watcher-listen', '~> 2.0.0' 44end 45 46group :test do 47 # Adds support for Capybara system testing and selenium driver 48 gem 'capybara', '>= 2.15' 49 gem 'selenium-webdriver' 50 # Easy installation and use of web drivers to run system tests with browsers 51 gem 'webdrivers' 52end 53 54# Windows does not include zoneinfo files, so bundle the tzinfo-data gem 55gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] 56gem 'pry-rails' 57# gem "haml-rails", ">= 1.0", '<= 2.0.1' 58gem 'devise' 59gem 'carrierwave' 60gem 'mini_magick' 61gem 'font-awesome-sass' 62gem 'haml-rails' 63gem 'erb2haml' 64gem 'jquery-rails' 65gem 'simple_calendar', '~> 2.0' 66group :production do 67 gem 'pg' 68end

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

自己解決

webpack、yarnをインストール後デプロイを行うとできた。

投稿2020/09/02 08:13

rrtts667

総合スコア18

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.50%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問