I am trying to install rbenv on my Debian 6 system for production. What is the best way to do this? I tried some links on the github wiki page (https://github.com/sstephenson/rbenv/wiki/Using-rbenv-in-production and https://github.com/sstephenson/rbenv/wiki/shared-install-of -rbenv ), but I wonder what the best practice is.
Is it better to install it by deploying a user or system? With the deployment user, it seems that rubies are not available to all users, even if I install it using rbenv global 1.9.3-p125 , and the gem commando is also not available. It must be something with my paths, because I only included
if [[ -d $HOME/.rbenv ]]; then export PATH="$HOME/.rbenv/bin:$PATH" eval "$(rbenv init -)" fi
in my user deployment .bashrc file. Does the passenger / apache know where my rubies are? Since apache works with www-data user.
With a system installation (see the link to the general installation above), I ran into some strange error that the rbenv command was not found and could not be compiled.
So what should I do? I want to use it for my production server so that I can easily switch between rubies in the future.
23tux source share