我有一个rails 3.1应用程序,我正在尝试推送到Heroku。当我推它时它会一直失败。
Installing sqlite3 (1.3.4) with native extensions Unfortunately, a fatal error has occurred. Please report this error to the Bundler issue tracker at https://github.com/carlhuda/bundler/issues so that we can fix it. Thanks!
/usr/local/lib/ruby/1.9.1/rubygems/installer.rb:483:in `rescue in block in build_extensions': ERROR: Failed to build gem native extension. (Gem::Installer::ExtensionBuildError)
/usr/local/bin/ruby extconf.rb
checking for sqlite3.h... no
sqlite3.h is missing. Try 'port install sqlite3 +universal'
or 'yum install sqlite3-devel' and check your shared library search path (the
location where your sqlite3 shared library is located).
我将我的gem文件更改为以下行:
gem 'sqlite3', :group => [:development, :test]
gem 'pg', :group => [:production]
即使在运行捆绑安装等后,我也收到了错误消息。我甚至在我的gem文件中运行了一些没有sqlite3的测试,它仍然试图在Heroku上安装它。有什么建议吗?
答案 0 :(得分:2)
大声笑,事实证明我正在一个分支上工作,正在推动我的主人。一旦我合并他们并推动正确的分支一切都很好。
答案 1 :(得分:1)
根据文档http://devcenter.heroku.com/articles/bundler,Cedar堆栈尚不支持bundle without
,因此仍会尝试在部署时安装它。
老实说,如果你正在部署的话,那么在本地使用postgres要好得多。