How to use frozen Capistrano part 2?

Following up on my question about using frozen Capistrano a couple of days ago, I am still having problems running Capistrano in my vendor folder.

When I try to run the frozen version of cap

ruby -r rubygems ./vendor/gems/capistrano-2.5.2/bin/cap deploy-with-migrations

      

I am getting the error

... RubyGem version error: net-ssh(1.0.8 not >= 2.0.0) (Gem::LoadError) ...

      

I have net-ssh-2.0.4 frozen in my vendor folder as I knew it was a dependency and how can I use it?

I was hoping to add my vendor folder to my .gemrc file under gempath: would do the trick, but it doesn't. The gem environment shows the vendor path, but the gem list does not show the gems in the vendor folder.

Any ideas?

0


source to share


2 answers


I ended up choosing not to freeze Capistrano and my vendor gem dependencies as they weren't gems used by my application - they were used to deploy my application.



Instead, I installed them locally on my hosting account and everything worked fine.

+1


source


If you want to avoid system gems entirely (not a bad idea if you don't have control over them), I would install a copy of rubygems in the vendor directory.



Set the environment variables GEM_PATH and GEM_HOME to / path / to / your / vendor / gems directory and then install rubygems from there.

0


source







All Articles