3

我正在尝试将我的应用程序推送到 Heroku,但被拒绝了。这是我收到的错误消息。

Counting objects: 63, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (56/56), done.
Writing objects: 100% (63/63), 80.06 KiB, done.
Total 63 (delta 10), reused 0 (delta 0)

-----> Heroku receiving push
 !     Heroku push rejected, no Cedar-supported app detected

To git@heroku.com:agile-shelf-2850.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:agile-shelf-2850.git'

我的应用程序是简单的 hello world 应用程序,我正在使用以下内容:

Rails 2.3.5 红宝石 1.8.7 宝石 1.4.2

我研究了该站点并发现其他有此问题但他们正在使用 Rails 3。示例:Heroku 推送被拒绝,未检测到 Cedar 支持的应用程序

有任何想法吗?我正在使用这些旧版本,因为我试图集成的项目正在使用这些版本,所以我试图保持一致。

4

1 回答 1

1

您需要将 config/environment.rb 中的 config.gem 行移动到 Gemfile 并安装捆绑程序。Rails 2.x 没有对 Bundler 的固有支持,Cedar 要求您使用 Bundler 来指定应用程序的 gem 依赖项。否则,它不会将您的应用视为 Rails 应用。

通过以下方式安装 Bundler for Rails 2.3:

http://gembundler.com/v1.3/rails23.html

如果之后您还有其他问题,请告诉我们!

于 2013-03-07T19:32:28.320 回答