81
https://github.com/intridea/omniauth.git (at master) is not checked out. Please run `bundle install` (Bundler::GitError)

So what do I do? bundle install works on development, but when I push and deploy to my production server. I get this error, even after running bundle install on my production server.

1
  • 6
    Even if your question is already solved, could you add some more context to it so it will be useful for other people having similar problems? What did you do to get this error message, for example? Aug 27, 2011 at 22:02

17 Answers 17

123

You're probably running Passenger. This is the issue with some solutions - http://code.google.com/p/phusion-passenger/issues/detail?id=505

Try running bundle install --deployment

8
  • Just a note, got a depreciation message running 3.0.9 stating that we should use bundle install path deployment. Jul 11, 2011 at 11:24
  • 10
    That masks the problem more than solves it – --deployment mode is not intended for development and poses problems with each bundle. Mar 16, 2014 at 22:21
  • 2
    "In deployment mode, Bundler will ´roll-out´ the bundle for production use." This vendors (copies) the gems into your development app, bloating the app's code. There must be a better way to solve the issue?
    – Dennis
    Feb 11, 2015 at 0:56
  • 2
    Regarding my previous comment: Try removing Gemfile.lock and .bundle/config from your project and running bundle install. (Note that the lack of a Gemfile.lock may cause some gems to update when you run bundle install.) It fixed the issue for me. Worth a try before you enable deployment mode in development or test environments.
    – Dennis
    Feb 11, 2015 at 1:23
  • 1
    In case you guys need it later, this is how you revert it: bundle install --no-deployment
    – Adrian Teh
    Aug 28, 2017 at 14:06
24

This error can be related to the spring gem. Regenerating spring binstubs worked for me.

bundle exec spring binstub --all

https://github.com/rails/spring/issues/387

14

for the guys that stuck with "bundle & git repo " problems.

bundle pack
bundle install --path vendor/cache

more details, please refer to https://stackoverflow.com/a/5268534/445908

0
6

For me it was just a matter of adding this to gemfile:

source 'http://gems.github.com'
1
6

When your computer never restarts, Spring might be the problem. Spring was running for 350 hours and caused caching the outdated TEST environment. I had this problem in my cucumber test environment in Rubymine. Strange this was that from (mac) the command prompt there was no problem.

spring status
spring stop

and voila! It all worked again.

1
  • This can also happen if you change your repo urls from git:// to https://. spring stop a.k.a. "have you tried turning it off and on again?" is the only (!) thing that will work in that case.
    – jaynetics
    Sep 20, 2016 at 13:33
6

Ran into this problem after upgrading to ruby 2.7.0

Looks like maybe there has been changes to deprecate the use of the business company focused:github => to the actual software platform focused :git =>. Maybe better for easier code logic maintainability.

Change the following:

gem 'devise', :github => 'plataformatec/devise'  

to the following:

gem 'devise', :git => 'git://github.com/plataformatec/devise'

An alternative is you may still reference :github as your git_source at the top of your Gemfile and just reference to the Gems as normal like so:

source 'https://rubygems.org'                                                                                                                             
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
...
gem 'devise'
2
  • 1
    This was the solution to my problem after upgrading too. Upvoted :)
    – paascal
    Apr 27, 2020 at 16:29
  • 1
    That fixed it for me as well. Much appreciated!
    – flacko
    Sep 7, 2021 at 11:35
4

If you run bundle install and then on attempt to run anything you see "... github.com ... is not yet checked out. Run bundle install first." - that means you need to use bundle exec before your command, e.g.:

bundle exec rails s
2

For anyone here in 2021, the accepted answer is outdated as --deployment flag is deprecated.

Use this instead:

bundle config set --local deployment 'true'
1

Installing gem locally in project directory fix it for me.

 $ bundle install --path vendor/bundle
1

This solution

$ bundle install --path vendor/bundle

has fixed my issue with running multiple rails app via foreman.

Note: Don't forget to execute rbenv rehash after if you are using rbenv.
And add /vendor/bundle in your .gitignore if not yet added.

1
  • Bundle is recommending to use bundle config set --local path 'vendor/bundle' instead as --path is deprecated.
    – Sylhare
    Nov 8, 2021 at 19:16
1

My problem was that i had no access to github

try ssh -vT [email protected] and see if you get

[email protected]: Permission denied (publickey).

Then see https://help.github.com/articles/error-permission-denied-publickey/

1

Another solution, that helped me when I was getting same issue while installing private gem from my Github repo, in Docker (my gems are in volume /gems):

# Add known host 
RUN mkdir -p -m 0600 ~/.ssh && ssh-keyscan github.com >> ~/.ssh/known_hosts

RUN bundle config set path /gems # this fixes issue with private repos DON'T USE ENV BUNDLE_PATH /gems
RUN --mount=type=ssh bundle install

To forward SSH, build using this command:

docker build --ssh default .
0

It is a permission error. The following worked

Environment : RVM with Apache

RVM user:group : rvm:rvm

Apache user:group : apache:apache

You need to add apache user to RVM group

usermod -a -G rvm apache
1
  • 1
    Also adding to the discussion: I was having the same problems, so I tried explicitly setting the user in nginx.conf to the user for which RVM was installed and it worked. So before it was commented out: #user nobody;, now it's: user jake. Apr 25, 2014 at 4:25
0

What finally helped me once and forever:

  1. Reinstalling everything as Galen suggested (all the steps from https://github.com/carlhuda/bundler/blob/master/ISSUES.md)

  2. Using bundle instead of rvmsudo bundle

0

Update your Gemfile as follows;

gem 'activeadmin', github: 'activeadmin/active_admin', branch: '0-6-stable'

and then,

bundle install

Iif still error occurs (because of you have tried 'bundle install --deployment', then try running)

bundle install --no-deployment
0

Restarting bash session helped for me

0

Recently I got the error message on Circle CI:

#!/bin/bash -eo pipefail
bundle exec rails db:setup

https://github.com/randym/axlsx.git (at c8ac844@c8ac844) is not yet checked out. Run `bundle install` first.

Exited with code exit status 1
CircleCI received exit code 1

This error happened when gem dependencies can not be resolved. So I switched back to pre release version in my Gemfile to fix it

-gem 'axlsx', github: 'randym/axlsx', ref: 'c8ac844572b25fda358cc01d2104720c4c42f450'
+gem 'axlsx', '3.0.0.pre'

and run update to update the gem dependencies

bundle update axlsx

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.