2011-10-10 162 views
0

每次我部署到我的生產服務器我得到對於使用git的路徑寶石以下錯誤:「包安裝」錯誤使用Git路徑寶石的Rails 3

git://github.com/odorcicd/example.git (at rails3) is not checked out. Please run `bundle install` (Bundler::PathError) 

我發現,如果我運行「bundle install --deployment」它解決了這個問題。但它會再次安裝我的所有寶石,並且必須在每次部署後執行。有沒有人找到比這更好的解決方案?

這是我的Gemfile中使用的git路徑的例子:

gem 'efax', :git => 'https://github.com/TTDaVeTT/efax.git' 
+2

通常,我使用':git =>「git:// github.com/foo_bar.git'沒有http url – apneadiving

回答

1

同樣在這裏的問題:我有這種寶石,需要一個git的起源。

gem "machinist_mongo", :git => "https://github.com/nmerouze/machinist_mongo.git", :require => "machinist/mongoid", :branch => "machinist2" 

從我發現的; bundle安裝了寶石,但不是在你的寶石 - 所以你必須得到軌道包括寶石具體莫名其妙......需要幫助的那部分。