Anthony Candaele

Joined

1,530 Experience
1 Lesson Completed
1 Question Solved

Activity

Posted in Ruby issue when doing cap deploy production

I see,

I changed the version in my Capfile to :

set :rbenv_ruby, '2.1.2-p95'

but now, when I run

cap production deploy

I get the error:

$cap production deploy
DEBUG[d2d51431] Running /usr/bin/env [ -d ~/.rbenv/versions/2.1.2-p95 ] on 95.85.5.6
DEBUG[d2d51431] Command: [ -d ~/.rbenv/versions/2.1.2-p95 ]
DEBUG[d2d51431] Finished in 0.980 seconds with exit status 1 (failed).
ERRORrbenv: 2.1.2-p95 is not installed or not found in ~/.rbenv/versions/2.1.2-p95
cap aborted!
SSHKit::Runner::ExecuteError: Exception while executing on host 95.85.5.6: exit
/Users/acandael/Sites/posplus/vendor/bundle/bundler/gems/rbenv-2332dba20ec1/lib/capistrano/tasks/rbenv.rake:12:in `exit'
/Users/acandael/Sites/posplus/vendor/bundle/bundler/gems/rbenv-2332dba20ec1/lib/capistrano/tasks/rbenv.rake:12:in `block (3 levels) in     <top (required)>'
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/backends/netssh.rb:54:in `instance_exec'
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/backends/netssh.rb:54:in `run'
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/runners/parallel.rb:13:in `block (2 levels) in execute'

SystemExit: exit
/Users/acandael/Sites/posplus/vendor/bundle/bundler/gems/rbenv-2332dba20ec1/lib/capistrano/tasks/rbenv.rake:12:in exit'
/Users/acandael/Sites/posplus/vendor/bundle/bundler/gems/rbenv-2332dba20ec1/lib/capistrano/tasks/rbenv.rake:12:in
block (3 levels) in '
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/backends/netssh.rb:54:in instance_exec'
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/backends/netssh.rb:54:in
run'
/Users/acandael/Sites/posplus/vendor/bundle/gems/sshkit-1.5.1/lib/sshkit/runners/parallel.rb:13:in `block (2 levels) in execute'
Tasks: TOP => rbenv:validate
(See full trace by running task with --trace)

I don't understand this, I ran 'ruby -v' on my Digital Ocean vps and it told me the Ruby version is:

ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux]

greetings,

Anthony

Posted in Deploy Rails guide confusion

ok, now I could edit the file.

As I haven't registered a domain name yet, I used 'localhost' for server_name.

Thanks Chris,

Anthony

Posted in Deploy Rails guide confusion

Hi,

I'm deploying my Rails app, using this website's Deploy Rails guide.

Something is not really clear, at the end of the guide, under the section 'Adding The Nginx Host' it says:

"Open up /etc/nginx/sites-enabled/default in your text editor and we will replace the file's contents with the following:"

It's not clear to me where to open this file, is it on the VPS or on my local machine. I tried to edit this file on my Digital Ocean VPS, logged in as deploy user, but apparently the file is readonly and I couldn't save my edits.

thanks for your help,

Anthony

Posted in Ruby issue when doing cap deploy production

Hi, I'm following the Deploy Rails guide.

However, when I run

cap production deploy

I'm getting this error message:

$cap production deploy
DEBUG[be6b6bd6] Running /usr/bin/env [ -d ~/.rbenv/versions/2.0.0-p451 ] on 95.85.5.6
DEBUG[be6b6bd6] Command: [ -d ~/.rbenv/versions/2.0.0-p451 ]
DEBUG[be6b6bd6] Finished in 1.060 seconds with exit status 1 (failed).
ERRORrbenv: 2.0.0-p451 is not installed or not found in ~/.rbenv/versions/2.0.0-p451
cap aborted!

Not sure what's going on. I guess it has something to do with incompatible versions of Ruby, but is it the Ruby version on my local machine or on the VPS?

thanks for your help,

Anthony

Posted in deploy Rails

I wanted to delete my own comment, but apparantly this is not possible!

Posted in deploy Rails

I following the deploy rails instructions on GoRails.

When I tried to install Ruby 2.1.2 with rbenv, I got this error message:

"no acceptable c compiler found in $PATH"

I solved it by running this command as root user:

apt-get install build-essential

I found the solution on StackOverflow: http://stackoverflow.com/questions/19816275/no-acceptable-c-compiler-found-in-path-when-installing-python

just wanted to report, for people running in the same issue as I am.

greetings,

Anthony