Ruby on Rails Development Setup for Beginners
In this blog post I will assist you in installing a Ruby on Rails development environment with a simple step-by-step process.
Last updated
Was this helpful?
In this blog post I will assist you in installing a Ruby on Rails development environment with a simple step-by-step process.
Last updated
Was this helpful?
Today we will install Ruby on Rails (RoR) on a Debian Linux operating system ( LTS). With that said, RoR is compatible with other operating systems with just a few tweaks. This blog will assist you in installing RoR with a simple step-by-step process. Your installation may differ, for other operating systems refer to .
I am new to developing and have been using LTS, a flavor of Debian Linux, for my projects. This blog will provide the steps and information needed to get the environment and dependencies installed for RoR so you can get your first project going.
Ruby on Rails is an excellent framework for web application development. For those of you who are new to RoR, like me, you will need to install several different applications (referred to as dependencies) to ensure this runs smoothly.
Here are the packages, tools, and databases we will be installing:
- A distributed version control system.
Create a GitHub account - Our preferred vendor that allows us to host git repositories in the cloud.
- Secure Shell is a protocol that allows users to control and modify their remote servers over the Internet while ensuring security.
- Software package manager that simplifies the installation process for Mac OSX and Linux.
- A tool that manages, installs and runs multiple versions of Ruby.
- My preferred code editor.
- A used for long term storage.
- A used for short term storage (caching).
- Javascript runtime environment. Runs on the Chrome V8 engine and executes javascript code outside of a web browser.
- A more secure npm (node package manager - gets installed with NodeJS).
Here we will be navigating through the steps to get your Ruby on Rails development environment setup and all of the dependencies installed.
You will need to run the commands below in your terminal to install git.
If there are none, you will then run the next commands to generate a new one.
Next, press ENTER.
Next you will be giving it your information.
Once you have the SSH key generated you will need to add it to the ssh-agent to manage. In the command line enter:
To add it, ENTER.
Now rbenv should be installed, but we also need to add some startup scripts to your bash profile, so that your terminal uses rbenv instead of the system wide Ruby version.
For our setup, letβs run the latest and greatest (as of this writing) version of Ruby (3.0.1). To install this version of Ruby, we will use rbenv. Run the following in your terminal:
Remember git is the program for distributed version control, and is our preferred vendor. So, if you havenβt already, create an account with GitHub.
You will need to and connect it to GitHub. We will first check to see if there are any existing SSH keys. Run this command to see if there are any pre-existing SSH keys.
The final step is to add it to GitHub. Follow to do so.
is a package manager (similar to apt-get) that helps us install other packages to our system. To get the Homebrew package installed, you will have to run the below command:
Remember, is a tool that will help us manage installing and running multiple version of Ruby. To install rbenv, run the following:
You can follow the directions in the link to get the correct version installed on your device.
will be our relational database preference for our RoR setup. To install:
is our key value database that RoR uses for caching.
The link will take you through the steps to get the correct version of installed to your device and will give a thorough understanding.
For the final step we will be installing the package manager ) by running the command below.
Now that your environment is ready, you can dive into your first project. All in all, Ruby on Rails is a great development environment. It is easy to navigate, scalable, and is excellent for team projects. Looking for more useful information for Ruby on Rails? Check out this .