启动ruby服务器时出错

时间:2012-10-31 12:51:41

标签: ruby-on-rails ruby

我是红宝石的新手。我正在尝试使用命令bundle exec rails server -p 3018启动ruby服务器。但我收到以下错误。我检查了代码,没有newrelic.yml文件。

Cannot find or read /Users/hjodiawalla/Downloads/TheGiftsProject-Plugin/config/newrelic.yml
Exiting
/Library/Ruby/Gems/1.8/gems/activerecord-3.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:928:in 'initialize': could not connect to server: Connection refused (PG::Error)
Is the server running on host "localhost" and accepting TCP/IP connections on port 5432? could not connect to server: Connection refused
Is the server running on host "localhost" and accepting TCP/IP connections on port 5432? could not connect to server: Connection refused
Is the server running on host "localhost" and accepting TCP/IP connections on port 5432?
    from /Library/Ruby/Gems/1.8/gems/activerecord-3.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:928:in 'connect'
    from /Library/Ruby/Gems/1.8/gems/activerecord-3.0.3/lib/active_record/connection_adapters/postgresql_adapter.rb:928:in 'connect'

如何解决此问题。服务器之前使用相同的配置工作。所以我在这里错过了什么。

1 个答案:

答案 0 :(得分:1)

您必须安装config/newrelic.yml文件。 (docs