簡體   English   中英

Puma Web服務器,使用默認的Web服務器(webrick)未檢測到Procfile

[英]Puma Web Server No Procfile detected, using the default web server (webrick)

嘗試將Puma Web Server與heroku一起使用。 我使用以下命令創建了一個名為“ Procfile”的Procfile。

web: bundle exec puma -C config/puma.rb

我也有一個config / puma.rb文件,內容如下。

workers Integer(ENV['WEB_CONCURRENCY'] || 2)
threads_count = Integer(ENV['MAX_THREADS'] || 5)
threads threads_count, threads_count

preload_app!

rackup      DefaultRackup
port        ENV['PORT']     || 3000
environment ENV['RACK_ENV'] || 'development'

on_worker_boot do 
   ActiveRecord::Base.establish_connection
end

我在終端收到以下警告

$git push heroku master

###### WARNING:
remote:        No Procfile detected, using the default web server (webrick)
$git run bash

Bash確認它正在運行

$ls 

顯示所有文件。 Procfile被識別為擴展名為Procfile.rtf

刪除以前的Procfile。 創建了另一個Procfile並確保沒有擴展名。 然后運行以下命令:

$Git add .
$Git commit -m "Procfile" 
$Git push heroku master

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM