Setting up Cloud9

mattwr18 edited this page Aug 17, 2018 · 28 revisions

Cloud9 is the recommended and fastest way to get started: entirely browser-based, so works on any computer, even inexpensive Chromebooks. We have tested this on connections as slow as 256 Kbps (2G cellular data).

The free account is sufficient for doing course homeworks and developing small projects, but you will still need to deploy to Heroku.

Cloud9 Initial Setup

  1. Create and login to a free account on Cloud9 and select "Create a New Workspace". (Pro tip: if you don't already have a free account on GitHub, create that first, since you'll need one anyway, and you can then use your existing GitHub account credentials to login to Cloud9.)

  2. Click "Create a new workspace" and use the following options for your new workspace:

    • Workspace name and Description - anything you like
    • Hosted Workspace (not Remote SSH workspace)
    • Private or Public: your choice
    • Clone from Git or Mercurial: leave blank
    • Choose a template: select Blank Workspace (do not select "Rails" or "Ruby on Rails tutorial" or anything like that)
    • Then click Create.
  3. When your workspace appears, in the command shell window (lower pane of screen), run the following command (copy and paste to avoid typos - note; the command will take about 5 minutes to install all the necessary software on your C9 image.):

    curl -fsSL c9setup.saasbook.info | sudo bash --login && rvm use 2.4.0 --default
    
    
  4. From now on, use this same image for all assignments (don't create a new workspace per assignment).

  5. Finally, setup a public ssh keypair in your Cloud9 instance and add those keys to GitHub. Note: if the "clip" command to copy the SSH key to your clipboard in Step 4 of the GitHub instructions fails for you, then do this:

    cat ~/.ssh/id_rsa.pub
    

    This displays the contents of the file on the terminal. You can then select and copy the entire content starting from "ssh-rsa" including the key up to "your_email@example.com".

  6. to check that you can install the correct version of Rails you can run:

    $ gem install rails -v 4.2.10
    

Now you're all set up with Cloud9 you can leave your workspace alone until you need to work on an assignment.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.