turingschool-examples / task_manager_rails

2 stars 285 forks source link

Add support for common error when running `rails db:create`. #10

Open ghost opened 3 years ago

ghost commented 3 years ago

Getting the App Running

Before we can see what our new rails app can do, we need to do some more set up. First, let's create our app's database. Do this from the command line with:

rails db:create

You should see some output like this:

Created database 'task_manager_development'
Created database 'task_manager_test'

Notice how this created two databases.

If instead you saw something like this:

rails aborted!
ExecJS::RuntimeUnavailable: Could not find a JavaScript runtime. See https://github.com/rails/execjs for a list of available runtimes.

Since rails uses some JavaScript you may need to install node:
$ brew install node

Wyattwicks commented 3 years ago

The solution to the error is correct, brew install node fixed the issue for me.