OpenShift Quickstart for MongoDB & Ruby 1.9 Using MongoHQ


OpenShift & MongoHQ Integration

We’re proud to announce our partnership with OpenShift by Redhat, offering seamless hosted MongoDB integration into the OpenShift Platform. In collaboration with our friends at OpenShift, we’ve put together a quickstart to show off the ease of use of MongoHQ as well as the integration with OpenShift.

The Quickstart

Looking for a MongoDB and OpenShift solution? Have a working knowledge of Ruby? With our OpenShift tutorial, you can spend 5 minutes, and it will guide you through launching a quick Ruby, OpenShift, MongoDB, and Sinatra application. Technologist have loved acronyms since the LAMP days, so, we are calling this "SMOR". I've been on the lookout for a suitable technology that starts with an "E", so the world can test the SMORE stack.

Get started now:

1.  Create an account on <a href="">OpenShift</a>  
2.  Launch the "<a href="">MongoHQ on OpenShift</a>" cartridge  
3.  Visit the applications URL to start the guided tutorial  

And that’s it; you’re done! Your MongoHQ database is now connected to your OpenShift App. Enjoy!

The Code Details

With this quick start, we are using Sinatra which is programmed in Ruby and uses the Moped driver. To see the code base for the cartridge, go to: We are using the low level drivers and Sinatra to avoid hiding too much magic. The code will give you a good foundation for starting a Ruby and MongoDB project on OpenShift.

For more details about MongoHQ production database offering, take a look at our available plans. All MongoHQ deployments in us-east-1 are compatible with the OpenShift platform.

Chris Winslett
Chris Winslett is a complex arrangement of Oxygen, Carbon and Hydrogen. Includes some salt. And beer. Love this article? Head over to Chris Winslett’s author page to keep reading.

Conquer the Data Layer

Spend your time developing apps, not managing databases.