Install Ruby on Rails
Install RVM + Rails
Manage Ruby versions (production or not using RVM). Trust me, been there and installing it otherwise is not a walk in the park...
1~$ gpg2 --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
2~$ curl -sSL https://get.rvm.io | bash -s stable
3~$ curl -sSL https://get.rvm.io | bash -s stable --rails
RVM Already Installed But Without Rails
Make sure gem is installed under ~/.rvm. You should see something like below:
1~$ which gem
2/home/user/.rvm/rubies/ruby-3.0.0/bin/gem
and install rails
1~$ gem install rails
Once installation is complete, you should be able to verify rails version installed. Something like this:
1~$ rails --version
2Rails 7.0.2.2
See updated version in RVM website