Closed diasjorge closed 10 years ago
Thanks @diasjorge.
We've actually tried running bundler without the sudo with the Mavericks's system ruby and seen that it doesn't always prompt for the sudo password reliably. For now we'd like to keep the sudo. I'll plan to re-examine this more closely in the future.
Can you provide some details about what breaks when you do this? Could you please also confirm that you are in fact using the system ruby on a pristine Mavericks box when following the readme?
I can confirm this was done using system ruby.
When I used sudo, nothing was broken though or at least not that I noticed. I only used the system ruby for setting up the machine.
I also did the provisioning on another machine without sudo and it worked fine as well.
On 07/06/2014, at 23:23, Abhi Hiremagalur notifications@github.com wrote:
Thanks @diasjorge.
We've actually tried running bundler without the sudo with the Mavericks's system ruby and seen that it doesn't always prompt for the sudo password reliably. For now we'd like to keep the sudo. I'll plan to re-examine this more closely in the future.
Can you provide some details about what breaks when you do this? Could you please also confirm that you are in fact using the system ruby on a pristine Mavericks box when following the readme?
— Reply to this email directly or view it on GitHub.
Thanks @diasjorge. I just confirmed that bundle
works without the sudo
prefix on a pristine 10.9.3 machine.
I spoke with @indirect about this behavior, and he mentioned that bundler only asks for sudo when copying ruby bin files into GEM_HOME, which is hard coded to /usr/bin in OSXs system gem
binary.
I'm not sure if anything changed with 10.9.3, but it's probably best to leave sudo off any sort of gem installation – otherwise when system gems need to be modified any non-root user will receive error messages.
bundler also respects --path
to specify where gems get installed, so we could potentially use that if we run into problems (i.e. into .bundler/vendor or other similar locations in bundler's PATH
)
On 10.9 bundler doesn't appear to work without sudo. I tried this on a VM a few minutes ago.
Same set of steps works fine on 10.9.3.
Bundle raises a warning when executed with sudo.
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application for all non-root users on this machine.