You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've two servers (staging and vagrant). Both are set as a separate environments (config/deploy/staging.rb, config/deploy/vagrant.rb).
On staging I've user's rbenv (/~.rbenv), on vagrant it's system (/opt/rbenv).
deploy.rb:
set :rbenv_ruby, '2.1.2'
set :rbenv_map_bins, %w{rake gem bundle ruby rails}
set :rbenv_roles, :all # default value
staging.rb:
set :rbenv_custom_path, '~/.rbenv'
set :rbenv_type, :user
set :rbenv_prefix, "RBENV_ROOT=#{fetch(:rbenv_path)} RBENV_VERSION=#{fetch(:rbenv_ruby)} #{fetch(:rbenv_path)}/bin/rbenv exec"
vagrant.rb
set :rbenv_type, :system # or :system, depends on your rbenv setup
set :rbenv_custom_path, '/opt/rbenv'
set :rbenv_prefix, "RBENV_ROOT=#{fetch(:rbenv_path)} RBENV_VERSION=#{fetch(:rbenv_ruby)} #{fetch(:rbenv_path)}/bin/rbenv exec"
Whatever I'm runing (cap staging deploy, cap vagrant deploy) it always tries to use user rbenv and throws error if it's not found:
virvit$ cap vagrant deploy
DEBUG [fe6d5d20] Running /usr/bin/env [ ! -d ~/.rbenv/versions/2.1.2 ] on 192.168.33.10
DEBUG [fe6d5d20] Command: [ ! -d ~/.rbenv/versions/2.1.2 ]
DEBUG [fe6d5d20] Finished in 0.127 seconds with exit status 0 (successful).
ERROR rbenv: 2.1.2 is not installed or not found in ~/.rbenv/versions/2.1.2
Thank you for any advice or help.
The text was updated successfully, but these errors were encountered:
Hello.
I've two servers (staging and vagrant). Both are set as a separate environments (config/deploy/staging.rb, config/deploy/vagrant.rb).
On staging I've user's rbenv (/~.rbenv), on vagrant it's system (/opt/rbenv).
deploy.rb:
set :rbenv_ruby, '2.1.2'
set :rbenv_map_bins, %w{rake gem bundle ruby rails}
set :rbenv_roles, :all # default value
staging.rb:
set :rbenv_custom_path, '~/.rbenv'
set :rbenv_type, :user
set :rbenv_prefix, "RBENV_ROOT=#{fetch(:rbenv_path)} RBENV_VERSION=#{fetch(:rbenv_ruby)} #{fetch(:rbenv_path)}/bin/rbenv exec"
vagrant.rb
set :rbenv_type, :system # or :system, depends on your rbenv setup
set :rbenv_custom_path, '/opt/rbenv'
set :rbenv_prefix, "RBENV_ROOT=#{fetch(:rbenv_path)} RBENV_VERSION=#{fetch(:rbenv_ruby)} #{fetch(:rbenv_path)}/bin/rbenv exec"
Whatever I'm runing (cap staging deploy, cap vagrant deploy) it always tries to use user rbenv and throws error if it's not found:
virvit$ cap vagrant deploy
DEBUG [fe6d5d20] Running /usr/bin/env [ ! -d ~/.rbenv/versions/2.1.2 ] on 192.168.33.10
DEBUG [fe6d5d20] Command: [ ! -d ~/.rbenv/versions/2.1.2 ]
DEBUG [fe6d5d20] Finished in 0.127 seconds with exit status 0 (successful).
ERROR rbenv: 2.1.2 is not installed or not found in ~/.rbenv/versions/2.1.2
Thank you for any advice or help.
The text was updated successfully, but these errors were encountered: