-
Notifications
You must be signed in to change notification settings - Fork 7
Installing Rails on free Amazon EC2 Micro
This is how I setup and ran Rails on Amazon's free EC2 instance.
-
I signed up here: Amazon Elastic Compute Cloud (EC2)
FYI, requires credit card. -
I created a new instance and chose the default Amazon Machine Image (AMI) which ran Linux x86_64.
The RSA login key was generated and downloaded to my local machine.
I used the default configuration options for free Micro instance. -
I had to wait about a minute for the address for the instance to show up in the EC2 Management window.
Address wasec2-xxx-xxx-xxx-xxx.us-west-2.compute.amazonaws.com
-
Connect:
ssh -i downloaded_rsa_login_key.pem [email protected]
-
sudo yum update
for the 10 to 20 security updates. -
Test:
ruby -v
outputsruby 1.8.7 (2012-02-08 patchlevel 358) [x86_64-linux]
Remove: `sudo yum erase ruby' (This is probably optional) -
Install dependencies:
sudo yum install readline-devel git make zlib-devel sqlite-devel.x86_64 gcc g++ svn
I addedgcc
,g++
, andsvn
for a more flexible environment. -
Install RVM and latest stable Ruby:
curl -L https://get.rvm.io | bash -s stable --ruby
RVM Homepage -
Install rails: `gem install rails'
One hour later...and done.
Versions:
rvm -v
=> rvm 1.14.11 (stable) by Wayne E. Seguin <[email protected]>, Michal Papis <[email protected]> [https://rvm.io/]
ruby -v
=> ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
gem -v
=> 1.8.24
rails -v
=> Rails 3.2.7
05 August 2012