-
Notifications
You must be signed in to change notification settings - Fork 492
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
rvm_path setting not picking up #124
Comments
I get the same error and I could see rvm in the path. Did you get this working? |
wow umm so same problem....anyone with a solutions? Edit: umm so actually I just got it working...I apparently misspelled something -.-. False alarm! |
Same here :( |
Those who have made it work can please tell me what made it to work. |
I ended up having to use the path that is provided when you do Edit: I was mistaken. It's not |
I have a exact same problem. Is anybody solve it? I hardcoded |
@zolzaya pretty sure the hardcoded path should be something along the lines of |
Thank you for reply. But it's not work for me :(. How to find that path? I run |
hmm sorry the command is actually |
Here the full output of
I can't find
|
it shows your rvm path to be |
It's not work :( The error is exactly same |
I'm not really sure what else to look at. If you want you can put your deploy.rb file on pastebin and link it up here. The only thing I can think of is to make sure you have |
Thank you for trying to help me :). I'm installed multi-user. Here is the deploy.rb. For security reason I removed domain, deploy_to, repository configs. require 'mina/bundler'
require 'mina/rails'
require 'mina/git'
# require 'mina/rbenv' # for rbenv support. (http://rbenv.org)
require 'mina/rvm' # for rvm support. (http://rvm.io)
# Basic settings:
# domain - The hostname to SSH to.
# deploy_to - Path to deploy into.
# repository - Git repo to clone from. (needed by mina/git)
# branch - Branch name to deploy. (needed by mina/git)
set :branch, 'master'
# Manually create these paths in shared/ (eg: shared/config/database.yml) in your server.
# They will be linked in the 'deploy:link_shared_paths' step.
set :shared_paths, ['config/database.yml', 'log']
# Optional settings:
set :user, 'root' # Username in the server to SSH to.
# set :port, '30000' # SSH port number.
# ISSUE: https://github.com/nadarei/mina/issues/124
# set_default :rvm_path, '/usr/local/rvm/scripts/rvm'
# set_default :rvm_path, '/usr/local/rvm/bin/rvm'
set_default :rvm_path, '/usr/local/rvm/scripts/rvm'
# This task is the environment that is loaded for most commands, such as
# `mina deploy` or `mina rake`.
task :environment do
# If you're using rbenv, use this to load the rbenv environment.
# Be sure to commit your .rbenv-version to your repository.
# invoke :'rbenv:load'
# For those using RVM, use this to load an RVM version@gemset.
invoke :'rvm:use[ruby-2.0.0-p353@rails-4-1]'
end
# Put any custom mkdir's in here for when `mina setup` is ran.
# For Rails apps, we'll make some of the shared paths that are shared between
# all releases.
task :setup => :environment do
queue! %[mkdir -p "#{deploy_to}/shared/log"]
queue! %[chmod g+rx,u+rwx "#{deploy_to}/shared/log"]
queue! %[mkdir -p "#{deploy_to}/shared/config"]
queue! %[chmod g+rx,u+rwx "#{deploy_to}/shared/config"]
queue! %[touch "#{deploy_to}/shared/config/database.yml"]
queue %[echo "-----> Be sure to edit 'shared/config/database.yml'."]
end
desc "Deploys the current version to the server."
task :deploy => :environment do
deploy do
# Put things that will set up an empty directory into a fully set-up
# instance of your project.
invoke :'git:clone'
invoke :'deploy:link_shared_paths'
invoke :'bundle:install'
invoke :'rails:db_migrate'
invoke :'rails:assets_precompile'
# to :launch do
# queue "touch #{deploy_to}/tmp/restart.txt"
# end
end
end
# For help in making your deploy script, see the Mina documentation:
#
# - http://nadarei.co/mina
# - http://nadarei.co/mina/tasks
# - http://nadarei.co/mina/settings
# - http://nadarei.co/mina/helpers Added my gemsets:
|
Hmm the only thing I can think of that could affect you is I have it as |
Not work. I'm just give up :( |
@zolzaya Sorry. I wish I could help more but I'm actually pretty limited in my understanding of how to use mina. I sort of just hacked the default to work with my project. I keep meaning to go and read over the documentation when I get a chance but unfortunately that chance hasn't come up yet. Hopefully someone with an answer to your question can help you out. I'd say try stackoverflow and see if you can find someone on there to help. Best of luck! |
~$ echo $rvm_path
/usr/local/rvm I only changed |
I get the same problem: ! Command failed. I double checked several times. rvm is installed in the location I specified using rvm_path. EDIT: I'll fess up and say that it turns out I was being stupid and using the rvm path on my local machine. Hopefully this can help someone else - you want to use the rvm path on the server not your local machine. |
in my case worked ("set" instead of "set_default"): |
That set command fixed it for me! Thanks @NazarK |
thanks , use "set :rvm_path " |
Still have problem. The exact error message:
My deploy.rb:
What I did is changed user to 'deployer' and changed rvm_path
If I just connect through terminal to ssh as deployer, rvm works fine. PS I am using rbenv on local machine, I hope I don`t need to have rvm on local for correct mina operation? |
I don't see your repository var: |
I have cut that in '----- private info -----'. Actually, I found the source of half of my problems. It was default system shell of Ubuntu, which I use as server OS. It has |
use rvm_use_path path |
My server have system wide install of rvm at /usr/local/rvm/scripts/rvm .
when I try to set it in my deploy.rb as below
set :rvm_path, "/usr/local/rvm/scripts/rvm"
it is not getting set and so when I try to deploy, it fail with below error message
! Ruby Version Manager not found
! If RVM is installed, check your :rvm_path setting.
I also tried with set_default
set_default :rvm_path, "/usr/local/rvm/scripts/rvm"
But problem is still there.
when I tried by hardcoding the path in below file of the gem it work smoothly:
https://github.com/nadarei/mina/blob/master/lib/mina/rvm.rb
Below is the modification:
original line:
set_default :rvm_path, "$HOME/.rvm/scripts/rvm"
hardcoded line by me:
set_default :rvm_path, "/usr/local/rvm/scripts/rvm"
So, now it work, but hardcoding the path is not a solution for me or any one else.
can you guide me what going wrong here....
I have seen the online documentation of all the possible settings ( http://nadarei.co/mina/settings/ ) and find that you do not list rvm_path there.
is the gem not supporting this setting currently ..???
The text was updated successfully, but these errors were encountered: