加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

ruby-on-rails – 使用默认Web服务器(webrick)未检测到Procfile

发布时间:2020-12-17 03:29:20 所属栏目:百科 来源:网络整理
导读:在尝试部署我的 Ruby on Rails应用程序时,我得到了这个错误.这是我的命令行中的错误: ###### WARNING:remote: No Procfile detected,using the default web server (webrick)remote: https://devcenter.heroku.com/articles/ruby-default-web-serverremote:
在尝试部署我的 Ruby on Rails应用程序时,我得到了这个错误.这是我的命令行中的错误:

###### WARNING:
remote:        No Procfile detected,using the default web server (webrick)
remote:        https://devcenter.heroku.com/articles/ruby-default-web-server

remote:
remote: -----> Discovering process types
remote:        Procfile declares types -> (none)
remote:        Default types for Ruby  -> console,rake,web,worker
remote:
remote: -----> Compressing... done,29.5MB
remote: -----> Launching... done,v21
remote:        https://agile-sea-1900.herokuapp.com/ deployed to Heroku
remote:
remote: Verifying deploy... done.
To https://git.heroku.com/agile-sea-1900.git
   e5d3ad8..975d5eb  master -> master

我尝试按照“No Procfile detected,using the default web server”中的建议,但这没有帮助.

解决方法

在注释中给出的信息之外,您有此错误,因为在Procfile中,您有:

web: bundle exec rails server -p $PORT

因此将使用默认的webrick.

要删除此警告,您应使用另一个Web服务器,如Unicorn,Thin或Puma.

Heroku现在主张使用Puma(见Changelog).

要开始使用Puma和Heroku,您可以在Heroku网站上关注文章Deploying Rails Applications with the Puma Web Server.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读