[root@slave2 first]# rails s
/usr/local/rvm/gems/ruby-2.0.0-p481/gems/execjs-2.2.1/lib/execjs/runtimes.rb:51:in `autodetect': Could not find a JavaScript runtime. See https://github.com/sstephenson/execjs for a list of available runtimes. (ExecJS::RuntimeUnavailable)
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/execjs-2.2.1/lib/execjs.rb:5:in `<module:ExecJS>'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/execjs-2.2.1/lib/execjs.rb:4:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/uglifier-1.3.0/lib/uglifier.rb:3:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/uglifier-1.3.0/lib/uglifier.rb:3:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `block in require'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p481@global/gems/bundler-1.6.2/lib/bundler.rb:132:in `require'
from /root/rails/first/config/application.rb:7:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/railties-4.0.2/lib/rails/commands.rb:74:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/railties-4.0.2/lib/rails/commands.rb:74:in `block in <top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/railties-4.0.2/lib/rails/commands.rb:71:in `tap'
from /usr/local/rvm/gems/ruby-2.0.0-p481/gems/railties-4.0.2/lib/rails/commands.rb:71:in `<top (required)>'
from bin/rails:4:in `require'
from bin/rails:4:in `<main>'
[root@slave2 first]# yum install nodejs
Loaded plugins: fastestmirror, presto
Loading mirror speeds from cached hostfile
* base: mirror.bit.edu.cn
* epel: mirrors.yun-idc.com
* extras: mirrors.yun-idc.com
* updates: mirrors.yun-idc.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package nodejs.x86_64 0:0.10.29-1.el6 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
=======================================================================================================================================
Package Arch Version Repository Size
=======================================================================================================================================
Installing:
nodejs x86_64 0.10.29-1.el6 epel 498 k
Transaction Summary
=======================================================================================================================================
Install 1 Package(s)
Total download size: 498 k
Installed size: 1.5 M
Is this ok [y/N]: y
Downloading Packages:
Setting up and reading Presto delta metadata
Processing delta metadata
Package(s) data still to download: 498 k
nodejs-0.10.29-1.el6.x86_64.rpm | 498 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : nodejs-0.10.29-1.el6.x86_64 1/1
Verifying : nodejs-0.10.29-1.el6.x86_64 1/1
Installed:
nodejs.x86_64 0:0.10.29-1.el6
Complete!