This is my first website deployment and I'm quite a beginner in web development.
I am using Windows and Ruby on Rails and I am having a lot of trouble deploying my website online.
Also, I'm using FileZilla to send my files to the server.
Ruby version is 1.9.3 Rails version is 3.2.13
The error message that comes up is:
"Could not find a JavaScript runtime. See https://github.com/sstephenson/execjs for a list of available runtimes. (ExecJS::RuntimeUnavailable)"
I have tried the suggestion to add:
gem 'execjs'
gem 'therubyracer', :platforms => :ruby
to my Gemfile, however the following error arises:
"Could not find gem 'therubyracer (>= 0) ruby' in the gems available on this machine. (Bundler::GemNotFound)"
Furthermore, I've tried adding Node as per some suggestions, however I am having trouble using it to deploy the website, I am not sure how to use it exactly. Through the use of some research I've come across the suggestion to add the following code to my config/boot:
ENV['EXECJS_RUNTIME'] = 'Node'
and
Node = ExternalRuntime.new(
:name => "Node.js (V8)",
:command => "/usr/local/bin/node",
:runner_path => ExecJS.root + "/support/node_runner.js",
:encoding => 'UTF-8'
)
to my execjs runtimes.rb file, but then the following error comes up:
"Node.js (V8) runtime is not available on this system (ExecJS::RuntimeUnavailable)"
I am not sure if this is enough information or not, like I said I am a beginner but I have been struggling with this for a couple of days now.
Any advice would help.
Thanks a lot!