本文介绍了heroku推送被拒绝,未能编译Ruby / rails应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

遇到以下问题,BRAND NEW TO RoR,第一次试图上传应用程序上线,首先有托管问题,然后决定是否可以使用heroku修复它们,我只需使用带有heroku的自定义域。 ....这不是一个测试应用程序学习轨道的事情,我想部署用于我自己的业务内的实际应用程序,任何帮助将是伟大的,我已经搜索并没有看到这个问题的解决方案。 p>

请确保'gem install sqlite3 -v 1.3.7'在捆绑之前成功。

 未能通过Bundler安装gems 

Heroku推送被拒绝,未能编译Ruby / rails应用程序

[email protected]:peaceful-chamber-6371.git
[remote rejected] master - > master<预接收钩拒绝>
错误:无法将一些文件推送到'[email protected]:peaceful-chamber-6371.git

Gem File

  source'https:/ /rubygems.org'

gem'rails','3.2.12'

#Bundle edge Rails改为:
#gem'rails',::git = > 'git://github.com/rails/rails.git'
group:development,:test do
gem'sqlite3'
end
group:production do
gem'pg'
结束


#默认情况下,Gems仅用于资产并且在生产环境中不需要
#。
group:assets do
gem'sass-rails','〜> 3.2.3'
gem'咖啡栏','〜> 3.2.1'

#请参阅https://github.com/sstephenson/execjs#readme了解更多受支持的运行时间
#gem'therubyracer',:platforms => :ruby

gem'uglifier','> = 1.0.3'
gem'twitter-bootstrap-rails'
结束

gem' jquery-rails'

#使用ActiveModel has_secure_password
#gem'bcrypt-ruby','〜> 3.0.0'

#为JSON使用Jbuilder模板
#gem'jbuilder'

使用独角兽作为应用服务器
#gem' unicorn'

#使用Capistrano进行部署
#gem'capistrano'

#使用调试器
#gem'debugger'


解决方案

试试这个,

删除 Gemfile.lock 文件并执行 bundle install ,然后 git add git commit git push

Having the following issue, BRAND NEW TO RoR, first time ever trying to upload an app to go live, first had hosting issues, then decided if i could fix them with heroku i would just use a custom domain with heroku...... No this isnt a test app "learning rails" thing, actual app i want to deploy for use within the business I own, any help would be great, I have searched and havent seen a solution to this problem.

Make sure 'gem install sqlite3 -v 1.3.7' succeeds before bundling.

Failed to install gems via Bundler

Heroku push rejected, failed to compile Ruby/rails app

To [email protected]:peaceful-chamber-6371.git
[remote rejected] master -> master <pre-receive hook declined>
error: failed to push some refs to '[email protected]:peaceful-chamber-6371.git

Gem File

source 'https://rubygems.org'

gem 'rails', '3.2.12'

# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
group :development, :test do
gem 'sqlite3'
end
group :production do
  gem 'pg'
end


# Gems used only for assets and not required
# in production environments by default.
group :assets do
  gem 'sass-rails',   '~> 3.2.3'
  gem 'coffee-rails', '~> 3.2.1'

  # See https://github.com/sstephenson/execjs#readme for more supported runtimes
  # gem 'therubyracer', :platforms => :ruby

  gem 'uglifier', '>= 1.0.3'
  gem 'twitter-bootstrap-rails'
end

gem 'jquery-rails'

# To use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'

# To use Jbuilder templates for JSON
# gem 'jbuilder'

# Use unicorn as the app server
# gem 'unicorn'

# Deploy with Capistrano
# gem 'capistrano'

# To use debugger
# gem 'debugger'
解决方案

try this,

remove Gemfile.lock file and do bundle install , then git add, git commit and git push .

这篇关于heroku推送被拒绝,未能编译Ruby / rails应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-06 06:48