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

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

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

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

Ruby

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

Ruby on Rails

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

Q&A

0回答

989閲覧

【Ruby on Rails】本番環境でpumaが起動しない

maruineko

総合スコア12

Ruby on Rails 5

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

Ruby

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

Ruby on Rails

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

0グッド

0クリップ

投稿2020/02/15 10:26

railsアプリが本番環境で起動しないです。

sh

1[user@ip-172-31-38-222 disc_room]$ bundle exec puma -e production -C config/puma.rb 2bundler: failed to load command: puma (/home/user/.rbenv/versions/2.6.5/bin/puma) 3NameError: uninitialized constant #<Class:#<Puma::DSL:0x00000000014e3760>>::Rails 4 config/puma.rb:39:in `_load_from' 5 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/dsl.rb:43:in `instance_eval' 6 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/dsl.rb:43:in `_load_from' 7 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/configuration.rb:194:in `block in load' 8 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/configuration.rb:194:in `each' 9 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/configuration.rb:194:in `load' 10 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/launcher.rb:61:in `initialize' 11 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/cli.rb:71:in `new' 12 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/lib/puma/cli.rb:71:in `initialize' 13 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/bin/puma:8:in `new' 14 /home/user/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/puma-3.12.2/bin/puma:8:in `<top (required)>' 15 /home/user/.rbenv/versions/2.6.5/bin/puma:23:in `load' 16 /home/user/.rbenv/versions/2.6.5/bin/puma:23:in `<top (required)>'

config/puma.rbは、

ruby

1# Puma can serve each request in a thread from an internal thread pool. 2# The `threads` method setting takes two numbers: a minimum and maximum. 3# Any libraries that use thread pools should be configured to match 4# the maximum value specified for Puma. Default is set to 5 threads for minimum 5# and maximum; this matches the default thread size of Active Record. 6# 7threads_count = ENV.fetch("RAILS_MAX_THREADS") { 5 } 8threads threads_count, threads_count 9 10# Specifies the `port` that Puma will listen on to receive requests; default is 3000. 11# 12port ENV.fetch("PORT") { 3000 } 13 14# Specifies the `environment` that Puma will run in. 15# 16environment ENV.fetch("RAILS_ENV") { "development" } 17 18# Specifies the `pidfile` that Puma will use. 19pidfile ENV.fetch("PIDFILE") { "tmp/pids/server.pid" } 20 21# Specifies the number of `workers` to boot in clustered mode. 22# Workers are forked webserver processes. If using threads and workers together 23# the concurrency of the application would be max `threads` * `workers`. 24# Workers do not work on JRuby or Windows (both of which do not support 25# processes). 26# 27# workers ENV.fetch("WEB_CONCURRENCY") { 2 } 28 29# Use the `preload_app!` method when specifying a `workers` number. 30# This directive tells Puma to first boot the application and load code 31# before forking the application. This takes advantage of Copy On Write 32# process behavior so workers use less memory. 33# 34# preload_app! 35 36# Allow puma to be restarted by `rails restart` command. 37plugin :tmp_restart 38 39bind "unix://#{Rails.root}/tmp/sockets/puma.sock"

となっています。
原因がまったく分かりません。
どなたかご教授ください。

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

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

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

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

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

guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだ回答がついていません

会員登録して回答してみよう

アカウントをお持ちの方は

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

ただいまの回答率
85.48%

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

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

質問する

関連した質問