2016-10-27 36 views
0

我的rails 5在本地和heroku都有效。但为了提高性能,我遵循 heroku doc,它的工作很好(在heroku中),但Mac Book(2015)的操作系统10.12.1上的本地服务器出现连接错误,网络未在数据库连接时以日志错误开始。puma for heroku在本地获取错误

回答

0

在调试每一行之前添加到安装Puma之前推到heroku。我发现这行需要从config/puma.rg中删除

workers Integer(ENV['WEB_CONCURRENCY'] || 1) 

导致该问题。这确实不知道,因为从Heroku的商务部只提及

Multi process mode does not work if you are using JRuby or Windows because the JVM and Windows do not support processes. Omit this line from your config if you are using JRuby or Windows. 

所以,我认为无论是Mac的书或Mac OS 10.12.1应包括在列表中被省略。

删除该行后。本地和heroku都可以恢复工作。