Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export RBENV_ROOT before rbenv init for system-wide install #106

Closed
jgarber opened this issue Mar 3, 2013 · 2 comments
Closed

Export RBENV_ROOT before rbenv init for system-wide install #106

jgarber opened this issue Mar 3, 2013 · 2 comments

Comments

@jgarber
Copy link

jgarber commented Mar 3, 2013

I was having problems using rbenv with mina when it was installed system-wide (with fnichol's rbenv::system recipe).

I have set :rbenv_path, '/usr/local/rbenv' set in deploy.rb and an queue echo_cmd %{echo $PATH} before invoke :'bundle:install'.

       $ echo $PATH
       /home/vagrant/.rbenv/shims:/usr/local/rbenv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
-----> Installing gem dependencies using Bundler
       $ mkdir -p "/srv/myapp/shared/bundle"
       $ mkdir -p "./vendor"
       $ ln -s "/srv/myapp/shared/bundle" "./vendor/bundle"
       $ bundle install --without development:test --path "./vendor/bundle" --binstubs bin/ --deployment
       bash: line 118: bundle: command not found
 !     ERROR: Deploy failed.

To get rbenv to work, I set queue %{export RBENV_ROOT=#{rbenv_path}} before invoke :'rbenv:load'. Then I get:

       $ echo $PATH
       /usr/local/rbenv/shims:/usr/local/rbenv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
-----> Installing gem dependencies using Bundler
       $ mkdir -p "/srv/myapp/shared/bundle"
       $ mkdir -p "./vendor"
       $ ln -s "/srv/myapp/shared/bundle" "./vendor/bundle"
       $ bundle install --without development:test --path "./vendor/bundle" --binstubs bin/ --deployment
       Using rake (10.0.3) 
       ...
This was referenced May 9, 2013
@andrewhavens
Copy link

Awesome, thank you! This is exactly the same issue I was running into with my system-wide rbenv installation.

@jeremy
Copy link

jeremy commented Feb 15, 2014

This was fixed by #117.

@d4be4st d4be4st closed this as completed Jul 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants