Rails应用程序不会推送Heroku - 倾斜宝石

时间:2013-03-08 16:05:36

标签: ruby-on-rails ruby heroku gemfile tilt

这就是我的Gemfile的样子:

source 'https://rubygems.org'

ruby '1.9.3'

gem 'rails', '3.2.12'

# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'

gem 'pg'


# 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'
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'

gem 'heroku'
gem 'tilt'
gem 'execjs'
gem 'therubyracer'
group :development do
  gem 'taps'
  gem 'rvm'
end

这是我的Gemfile.lock文件的样子:

GEM
  remote: https://rubygems.org/
  specs:
    actionmailer (3.2.12)
      actionpack (= 3.2.12)
      mail (~> 2.4.4)
    actionpack (3.2.12)
      activemodel (= 3.2.12)
      activesupport (= 3.2.12)
      builder (~> 3.0.0)
      erubis (~> 2.7.0)
      journey (~> 1.0.4)
      rack (~> 1.4.5)
      rack-cache (~> 1.2)
      rack-test (~> 0.6.1)
      sprockets (~> 2.2.1)
    activemodel (3.2.12)
      activesupport (= 3.2.12)
      builder (~> 3.0.0)
    activerecord (3.2.12)
      activemodel (= 3.2.12)
      activesupport (= 3.2.12)
      arel (~> 3.0.2)
      tzinfo (~> 0.3.29)
    activeresource (3.2.12)
      activemodel (= 3.2.12)
      activesupport (= 3.2.12)
    activesupport (3.2.12)
      i18n (~> 0.6)
      multi_json (~> 1.0)
    addressable (2.3.3)
    arel (3.0.2)
    builder (3.0.4)
    coffee-rails (3.2.2)
      coffee-script (>= 2.2.0)
      railties (~> 3.2.0)
    coffee-script (2.2.0)
      coffee-script-source
      execjs
    coffee-script-source (1.6.1)
    erubis (2.7.0)
    excon (0.16.10)
    execjs (1.4.0)
      multi_json (~> 1.0)
    heroku (2.35.0)
      heroku-api (~> 0.3.7)
      launchy (>= 0.3.2)
      netrc (~> 0.7.7)
      rest-client (~> 1.6.1)
      rubyzip
    heroku-api (0.3.8)
      excon (~> 0.16.10)
    hike (1.2.1)
    i18n (0.6.4)
    journey (1.0.4)
    jquery-rails (2.2.1)
      railties (>= 3.0, < 5.0)
      thor (>= 0.14, < 2.0)
    json (1.7.7)
    kgio (2.8.0)
    launchy (2.2.0)
      addressable (~> 2.3)
    libv8 (3.11.8.13)
    mail (2.4.4)
      i18n (>= 0.4.0)
      mime-types (~> 1.16)
      treetop (~> 1.4.8)
    mime-types (1.21)
    multi_json (1.6.1)
    netrc (0.7.7)
    pg (0.14.1)
    polyglot (0.3.3)
    rack (1.4.5)
    rack-cache (1.2)
      rack (>= 0.4)
    rack-ssl (1.3.3)
      rack
    rack-test (0.6.2)
      rack (>= 1.0)
    rails (3.2.12)
      actionmailer (= 3.2.12)
      actionpack (= 3.2.12)
      activerecord (= 3.2.12)
      activeresource (= 3.2.12)
      activesupport (= 3.2.12)
      bundler (~> 1.0)
      railties (= 3.2.12)
    railties (3.2.12)
      actionpack (= 3.2.12)
      activesupport (= 3.2.12)
      rack-ssl (~> 1.3.2)
      rake (>= 0.8.7)
      rdoc (~> 3.4)
      thor (>= 0.14.6, < 2.0)
    raindrops (0.10.0)
    rake (10.0.3)
    rdoc (3.12.2)
      json (~> 1.4)
    ref (1.0.2)
    rest-client (1.6.7)
      mime-types (>= 1.16)
    rubyzip (0.9.9)
    sass (3.2.6)
    sass-rails (3.2.6)
      railties (~> 3.2.0)
      sass (>= 3.1.10)
      tilt (~> 1.3)
    sprockets (2.2.2)
      hike (~> 1.2)
      multi_json (~> 1.0)
      rack (~> 1.0)
      tilt (~> 1.1, != 1.3.0)
    therubyracer (0.11.4)
      libv8 (~> 3.11.8.12)
      ref
    thor (0.17.0)
    tilt (1.3.5)
    treetop (1.4.12)
      polyglot
      polyglot (>= 0.3.1)
    tzinfo (0.3.36)
    uglifier (1.3.0)
      execjs (>= 0.3.0)
      multi_json (~> 1.0, >= 1.0.2)
    unicorn (4.6.2)
      kgio (~> 2.6)
      rack
      raindrops (~> 0.7)

PLATFORMS
  ruby

DEPENDENCIES
  coffee-rails (~> 3.2.1)
  execjs
  heroku
  jquery-rails
  pg
  rails (= 3.2.12)
  sass-rails (~> 3.2.3)
  therubyracer
  uglifier (>= 1.0.3)
  unicorn

当我跑步时:

$ git push heroku master
Counting objects: 90, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (76/76), done.
Writing objects: 100% (90/90), 31.71 KiB, done.
Total 90 (delta 18), reused 0 (delta 0)

-----> Ruby/Rails app detected
-----> Using Ruby version: ruby-1.9.3
-----> Installing dependencies using Bundler version 1.3.0.pre.5
       Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin --deployment
       Fetching gem metadata from http://rubygems.org/.........
       Fetching gem metadata from http://rubygems.org/..
       Could not find tilt-1.3.5 in any of the sources
 !
 !     Failed to install gems via Bundler.
 !
 !     Heroku push rejected, failed to compile Ruby/rails app

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

我试图修复它的事情:

  • $ bundle install tilt
  • $ bundle update
  • 已删除.git和$ git init
  • 删除了gemfile.lock并再次安装了$ bundle
  • 登录并退出heroku
  • 重新启动计算机
  • 按照Heroku for RailsRails Apps上的说明进行操作,并通过所有关于heroku和rails的stackoverflow问题进行搜索,并对我建议的代码进行了更改。 (问题通常是关于sqlite数据库,但我已经解决了这个问题。)
  • 祈祷
  • 叫着

......但这一切都没有奏效。过去两天我一直在不停地进行故障排除。请帮忙。

2 个答案:

答案 0 :(得分:1)

似乎更新版本的倾斜存在问题。在你的Gemfile中尝试指定

gem 'tilt', '1.3.4'

答案 1 :(得分:0)

我已经这样做了

rm Gemfile.lock并执行bundle install,(!)然后git add .git commitgit push