SyntaxHighlighter JS

Showing posts with label ror. Show all posts
Showing posts with label ror. Show all posts

2018-10-29

Ruby on Rails json LoadError

Problem:
Running Ruby on Rails 'bin/rails s' and you get an error

in require: cannot load such file -- json (LoadError)


Solution:
Edit the Gemfile and add

gem 'json'


Installing Ruby on Rails on AWS Linux

To install Ruby on Rails on the AWS Linux VM, you need to install some prerequisites first.

sudo su -
yum install -y ruby24
alternatives --set ruby /usr/bin/ruby2.4
yum install -y ruby24-devel rubygems ruby24-devel gcc zlib-devel patch sqlite-devel
curl -sL https://rpm.nodesource.com/setup | bash -
yum install -y nodejs

gem install rails
rails --version