0

导轨 3.2.1,红宝石 1.9.3

我可以将我的应用程序推送到 Heroku,但是当我导航到该页面时它失败了。这是来自日志:

“处理请求时出现意外错误:请安装 postgresql 适配器:'gem install activerecord-postgresql-adapter'”

我已经在本地运行了该命令并且它有效。

我正在使用 sqlite3 进行开发,我的 gemfile 如下所示:

group :development, :test do
  gem 'sqlite3'
end
group :production do
  gem 'thin'
  gem 'pg'
end

知道我做错了什么/如何解决这个问题吗?谢谢你!

4

1 回答 1

0

I'm getting the same sort of error with the same sort of config.

2013-04-05T08:06:12+00:00 app[web.1]: Connecting to database specified by DATABASE_URL
2013-04-05T08:06:12+00:00 app[web.1]: !! Unexpected error while processing request: Please install the postgresql adapte
r: `gem install activerecord-postgresql-adapter` (pg is not part of the bundle. Add it to Gemfile.)

Have found that doing an update to the Gemfile (just adding whitespace) gets around the problem. It's a hassle though since it needs to be done every time any change is done.

于 2013-04-05T08:33:10.773 回答