没有检出... 捆绑包安装不修复帮助!

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

那我该怎么办?Bundle install 在开发时可以工作,但是当我将其推送并部署到我的生产服务器时。即使在我的生产服务器上运行 bundle 安装之后,也会出现这个错误。

53632 次浏览

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

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

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

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

1. $ bundle pack
2. $ bundle install --path vendor/cache

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

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

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

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

Installing gem locally in project directory fix it for me.

 $ bundle install --path vendor/bundle

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

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.

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.

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

My problem was that i had no access to github

try ssh -vT git@github.com and see if you get

git@github.com: Permission denied (publickey).

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

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'

Restarting bash session helped for me

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 .

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

Use this instead:

bundle config set --local deployment 'true'

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