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

recipe[rbenv::system_install] not adding to .bashrc #6

Closed
axsuul opened this issue Feb 21, 2012 · 5 comments
Closed

recipe[rbenv::system_install] not adding to .bashrc #6

axsuul opened this issue Feb 21, 2012 · 5 comments

Comments

@axsuul
Copy link

axsuul commented Feb 21, 2012

The recipe works good with installing ruby and setting the default ruby version, however, it doesn't append the PATH and rbenv init to my /etc/bash.bashrc. I'm still new to chef, so do I need to use a separate provider to do this? I see that there is a script provider that appears to do this.

I'm on Ubuntu 11.10

@fnichol
Copy link
Contributor

fnichol commented Feb 23, 2012

The rbenv::system_install recipe should create a /etc/profile.d/rbenv.sh file which gets sourced from /etc/profile (https://github.com/fnichol/chef-rbenv/blob/master/recipes/system_install.rb#L29-33 and https://github.com/fnichol/chef-rbenv/blob/master/templates/default/rbenv.sh.erb). When you log in does it not have rbenv in your PATH with which rbenv?

@ghost ghost assigned fnichol Feb 24, 2012
@ghost
Copy link

ghost commented Mar 26, 2012

Hi,

The file you mentioned is indeed created and I can access rbenv after I log back in. Is there anyway to make the variables in this file available without logging back in? At the moment my cookbook installs rbenv using this cookbook and then goes on to execute other commands with require gems installed using rbenv, however as the PATH has not been amended I cannot see the install gems without calling source /etc/profile.d/rbenv.sh. It also means other cookbooks which rely on the version of ruby being used don't work i.e. passenger_apache2.

Any help would be greatly appreciated. Thanks for the great cookbook.

@piousbox
Copy link

piousbox commented Apr 4, 2012

+1 this is a problem for me.

@fnichol
Copy link
Contributor

fnichol commented May 4, 2012

Hi all, pull request #8 was merged in and should address this. If that's not the case, then please reopen. Thanks!

@fnichol fnichol closed this as completed May 4, 2012
GUI pushed a commit to NREL-cookbooks/rbenv that referenced this issue Mar 10, 2013
install libreadline-dev in Ubuntu & Debian so irb will work
@lock
Copy link

lock bot commented May 31, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators May 31, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants