Bundle install worked. But when I git push heroku master, I got this:
C:\Sites\first_app>git push heroku master Warning: Permanently added the RSA host key for IP address '184.108.40.206' t list of known hosts. Counting objects: 65, done. Delta compression using up to 8 threads. Compressing objects: 100% (51/51), done. Writing objects: 100% (65/65), 26.10 KiB, done. Total 65 (delta 3), reused 0 (delta 0) -----> Heroku receiving push -----> Ruby/Rails app detected -----> Installing dependencies using Bundler version 1.1.2 Running: bundle install --without development:test --path vendor/bun -binstubs bin/ Fetching gem metadata from https://rubygems.org/......... Bundler could not find compatible versions for gem "railties": In Gemfile: rails (= 3.2.1) ruby depends on railties (= 3.2.1) ruby jquery-rails (= 2.0.0) ruby depends on railties (3.2.3) Failed to install gems via Bundler. Heroku push rejected, failed to compile Ruby/rails app To email@example.com:evening-frost-9408.git [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'firstname.lastname@example.org:evening-frost-9408.git'
Here is my Gem file:
source 'https://rubygems.org' gem 'rails', '3.2.1' # Bundle edge Rails instead: # gem 'rails', :git => 'git://github.com/rails/rails.git' group :development do gem 'sqlite3', '1.3.5' end # Gems used only for assets and not required # in production environments by default. group :assets do gem 'sass-rails', '3.2.4' gem 'coffee-rails', '3.2.2' gem 'uglifier', '1.2.3' end gem 'jquery-rails', '2.0.0' # To use ActiveModel has_secure_password # gem 'bcrypt-ruby', '~> 3.0.0' # To use Jbuilder templates for JSON # gem 'jbuilder' # Use unicorn as the web server # gem 'unicorn' # Deploy with Capistrano # gem 'capistrano' # To use debugger # gem 'ruby-debug19', :require => 'ruby-debug'
I'm basically following Ruby on Rails tutorial. But the rails I have is 3.2.1, but the online book says rails 3.2.3. I tried changing it to 3.2.3 and ~>3.2.3, I still get the same error message
preguntado el 03 de mayo de 12 a las 16:05
I had the same problem, I could not run 'bundle install' and same problem when trying to deploy on heroku (and I'm following the same tutorial).
Found a good answer aquí: rubygems.org does not serve HTTPS, so change the header of your gemfile from
I had a similar problem and figured I'd add my solution.
Originally my main project was seperated into gems that were included into the main project. As the coupling between the gems and the project increased, it made sense to bring the code for the gems directly into /lib of the main rails project. During the merge, the .gitignore files were merged without any conflicts. Unfortunately, a .gitignore for a gem is very different than for a standalone project. As I proceeded, when I updated a gem locally it would fail on the remote push deploy to Heroku. It turns out the .gitignore from the gem had things like
*.gem en ella.
TLDR; make sure your .gitignore file is sane