Install Ruby on Rails (web development) environment on Chromebook using Crouton

Web development on a Chromebook. Is it possible? Even if its possible, does it work well? It does! I develop web applications, mainly using Ruby on Rails on my Chromebook. I used to use to 15 inch MacBook Pro, but since I travel almost every month, after a while, lugging my macbook around was a real pain in the back. For the last year or so I've been using an Asus C302A Flip Chromebook. At first, I wasn't sure the Chromebook was going to be able to cope with web app development using Ruby on Rails, but I was pleasantly surprised.

In this post I'm going to document how I set up ubuntu on my Chromebook for local web development. Please note that I've already put my Chromebook in developer mode, installed Crouton and created an ubuntu chroot. If you haven't done it here's a guide on installing crouton and chroots on your chromebook.

Once you're all set up, follow these steps to set up Ruby on Rails on your new Ubuntu Chroot.

  1. Open Chrome
  2. Press CTRL + ALT + T
sudo enter-chroot -n ubunutu

The '-n' let's you pass a name to your chroot. Hopefully you named your chroot. If you only have one chroot, you can skip the '-n ubuntu'. If you have multiple chroots, and you didn't name yours then the default name will be the release name, something like 'xenial'.

Congratulations, you're now logged in to your virtual ubuntu machine. Now for the fun part.

Install Git:

sudo apt-get install git

Install Curl:

sudo apt-get install curl

Install RVM (Ruby Version Manager)

sudo curl -sSL | bash -s stable

Ah, I got a failure. Something to do with GPG keys.

sudo curl -sSL | gpg --import -

OK now rerun the previous curl command to get rvm. You should see a success message like this:

Installation of RVM in /home/user/.rvm/ is almost complete:

  * To start using RVM you need to run `source /home/user/.rvm/scripts/rvm` or source ~/.rvm/scripts/rvm
    in all your open shell windows, in rare cases you need to reopen all shell windows.

Let's check we have the latest version installed.

rvm get stable

Now we need to get the system ready for Ruby

rvm requirements

What ruby versions can we install? Let's check.

rvm list rubies

2.4 is the latest. If I'm not mistaken the app I want to work on runs on 2.2, so I'm going to install that.

rvm install 2.2

Wait a while….

ruby -v
ruby 2.2.7p470 (2017-03-28 revision 58194) [x86_64-linux]

To avoid conflicts between ruby versions, we'll create a gemset to use with this ruby version.

rvm use 2.2@r2.2_default --create --default
Using /home/chirag/.rvm/gems/ruby-2.2.7 with gemset r2.2_default

Before we install rails, we should tell rubygems not to create any documentation. Use your text editor to edit the file. I'm using VIM.

vim ~/.gemrc

Add the following two lines in the file and save.

install: --no-rdoc --no-ri
update:  --no-rdoc --no-ri

Now you can install rails. I'm using 4.2.10

gem install rails --version 4.0.8

We need to perform some one time set up if this is the first time you're using git.

git config --global "Your Full Name"
git config --global
git config --global checkout

Once you're in a folder where you want to work

git init

If you're working on code that's already on a repository

git remote add origin

To use this we need to set up ssh keys for bitbucket.

ssh-keygen -f ~/.ssh/<bitbucketusername>
ssh-add ~/.ssh/<username>
cat ~/.ssh/<username>.pub

Paste the contents into bitbucket. Follow these instructions. 

Now grab your repository. Use clone instead of pull as it will set up remote tracking.

git clone

You should be ready to roll if you downloaded an existing rails project. Enjoy!

Web App Challenge Status Report

Back in January I threw down the gauntlet and decided to take on the web app challenge. I said I would make a profit. I also said I would be transparent.

So here it is. An update.

The past couple months have been a crazy journey. I’ve taught myself Ruby on Rails. I’ve written 80% of a web application that works. And I’ve even learnt how to deploy it to a VPS myself.

That’s not all. I also had the time to make a marketing site and get the app tested by a potential end user.

Let me be honest. My app is nowhere near finished or ready for sale, but I am getting there. To be perfectly honest I’m finding it really tough to juggle my full time day job, family and social commitments and working on the app. I’m getting there, but not as fast as I’d like.

In case you don’t already know I am building software for property management and lettings agents in the UK.
I haven’t been tracking my time so I can’t say how long I’ve spent on the app so far. I’ve spent under £300GBP on a VPS and domain names.

Right now I think I’m over complicating some functionality and that’s stopped me from implementing anything other than bug fixes for a while. If you’re good with modelling data or would like to test my app please get in touch!

Scratch your own itch

When you’re building a product, web app or otherwise, the de facto advice is to “scratch your own itch”. It makes sense. Find a problem which bothers you enough to take some action to solve it. Ideally, you won’t be the only person with the same problem and others will be experiencing enough pain to do something about it i.e. pay you for your solution.

If you’ve been following my posts lately, you’ll know I’m midway through month two of my web app challenge. Going against conventional wisdom I’m not scratching my own itch – I’m scratching someone else’s (that sounds wrong…but you get what I mean).

Now although the itch isn’t mine, it belongs to someone close to me and I feel their pain.

What’s the pain?

90% of their business activities are recurring repetitive tasks that could be automated. Right now they do everything manually – yes, manually.

Is there a solution out there?

Yep, plenty. We could use one of these existing solutions but decided against it. After speaking to several businesses in the same industry the consensus was that existing providers were either too expensive, too hard to use or a combination of the two.

Another thing I noticed was that many of the existing providers didn’t offer an overly “user friendly” web based offering. Instead they required to customer to have on site equipment (severs etc) to run their applications. On top of this most providers (in the UK at least) seemed to have websites that looked dated and didn’t demonstrate their product well.

There were some exceptions to this of course and I made use of free trials where available. I found that whilst many performed the job they were not intuitively easy to use.

What am I building?

I’m building a property management application. The person who’s itch I’m scratching is my Father. Whilst his business is a lot more than just property rentals, this is the area I’m choosing to focus on as it’s where they are experiencing growth and need a solution thats more scalable than spreadsheets and files in filing cabinets.

It’s nice to have access to a “subject matter expert” at home, but I’m also in touch with similar businesses to ensure I build a tool that caters to the majority of needs rather than something bespoke for my Dad.

How much time have I spent?

Keeping in mind I have a day job, I’ve had to make some hard decisions about how to spend my out-of-work hours. I try to make it to the gym 3 times a week and leave Friday/Saturday evenings for socialising. The rest of the week I try to work pretty much immediately after getting in from work until bedtime.

I’ve found staying motivated is hard. It’s even harder to get to work after “relaxing” in front of the TV for an hour. In my head I keep telling myself, I’ll have more time to watch TV after July. It’s been tough and some days I get nothing done, but having limited time is keeping me focused.

I haven’t done any specific time tracking, but my guess is about 10 -15 hours a week.

“The one human quality that must be developed is self discipline for success. The will power to force yourself to do what you know you should do when you should do it, whether you like it or not, whether you feel like it or not. Success is tons of discipline.” — Brian Tracy

Where are the links I promised last post?

In my last post I mentioned I had been in touch with a great bunch of guys working on their own web app challenges. They’ve been a great source of motivation and inspiration so far. Here are links to their blogs/projects:

App Name App Author Target Monthly Income
by July 2013
App Description
Convert Kit Nathan Barry $5000 (USD) An app to help improve the conversion rate of your landing pages and make the set up of auto responder email courses easier. Martyn Garcia 10 paying customers The best conversion optimization platform the world has ever seen. Developer and designer friendly.
The Niche Finder Paul Devlin $5001 (USD) A tool that scans eBay recording product metrics such as how many of each product the seller has sold each month. The products are then displayed in a best seller list so users can find popular products at a glance.
ThankBee Rob Chava $1000 (USD) With ThankBee, Android app developers can:

  • Invite buyers to friend them on Facebook, follow them on Twitter, or to join their mailing list.
  • Invite users to give them valuable comments and feedback (possibly solving issues that would normally end up as negative reviews).
  • Promote their other apps and services.
  • Offer special discounts or trial codes to users who cancelled their purchase.
Procedure Office Will Claxton $500 (USD) Virtual Assistant Management Software

  • Manage any number of Virtual Assistants easily all from one simple to use dashboard
  • Create Standard Operating Procedures (SOPs) for quick reference to common repeatable tasks
  • Custom Tasks & SOPs have colour coded Priority Levels
  • Set SOPs to Re-occur on the VA’s to-do list
  • Business Owners receive notifications if scheduled SOPs not completed on time
  • Statistics on task completion timing and scheduled SOP completion percentages
  • VA’s can have multiple clients, this makes managing daily workload much simpler as everything is in one location.
Property Management App CD £3000 GBP (~$4700 USD) An easy to use, web-based Property Management Tool for UK based Letting Agents

The Web App Challenge: £0 to £3000/month in six months

It’s a new year. Time to re-focus on those life goals and keep life heading in the desired direction.

I was reading Nathan Barry’s blog today and have decided to join him in the Web App challenge. Unlike Nathan, I have some idea about the web application I want to build, but I’m still researching and planning at the moment. To be honest Nathan’s post couldn’t have come at a better time. I’m hoping to be just as transparent and take inspiration from his aggressive approach and tight timeline (leaving me less time to procrastinate!).

What our challenges have in common

– Extracting ideas in the style of Dane Maxwell

– Building a web application

– Using Ruby on Rails

– Looking for to create a SaaS (software as a service) product.

How our challenges will differ

Unlike Nathan, I’m assigning a budget of ZERO. I plan on doing the design / development / marketing etc by myself, whilst working full time at my job (which is often more than the usual 9 to 5).

I have experience in programming with Ruby and Rails, but have never built a full web app, especially one I intended to sell. I’m hoping the next few months will solidify my knowledge of Rails and allow me to create software that provides real value to my eventual target market.

Join in?

Whilst the Web App Challenge isn’t an official challenge (as far as I know), I encourage you to join in. It would be nice to have some community to share the ups and downs and building a software product with. Besides, what better way to start the new year than to start working on a new project?

To our successes in 2013! Happy new year 🙂

— CD