Skip to content

Latest commit

 

History

History
53 lines (34 loc) · 4.45 KB

installing-datajam.md

File metadata and controls

53 lines (34 loc) · 4.45 KB

Setting Up Datajam

Learn how to install and configure our award-winning real-time reporting platform, Datajam. It's the platform that powers our own Sunlight Live and can enable real-time reporting, context and analysis on your site quickly, easily and cheaply. Datajam is a real-time reporting platform created by the Sunlight Foundation. The concept of Datajam is to simplify reporting live events in real time with a focus on displaying contextual data and information in accessible ways.

We call our implementation Sunlight Live, but the underlying platform is called Datajam and has been made freely available to the public.

There are three basic components to the Datajam platform:

  • Live video stream: To embed video into the platform, simply paste video embed code into this module.
  • Real-time chat: With connections to social networks and URL shorteners, this chat module was built by Sunlight Labs from the ground up. It includes a comment moderation interface to keep conversations civil and on track.
  • Contextual data cards: Our datacard system makes it easy for hosts to create contextual data cards featuring tables, charts and graphs. Included with Datajam is a plugin to connect automatically to our Influence Explorer site.

So, let's walk through installing Datajam for your own use.

We built Datajam as a Ruby on Rails application that can be deployed in any number of ways. We think the easiest is through the Heroku cloud-based application hosting environment. For the purposes of this module, that's the setup we're going to assume.

There are two pieces of software that must first be installed on your computer before you can continue. They are Ruby and Git. You can get more information about each and how to install them here:

Mac: Ruby | Git Linux: Ruby | Git Windows: Ruby | Git

My Heroku

Once you've set up your local machine with Ruby and Git, you’ll next need to sign up for a free Heroku account. Sign up at https://api.heroku.com/signup.

Heroku has various service levels, including basic service that is free and would be sufficient for running small Datajam events. As your events grow, Heroku can scale services accordingly at pretty low rates. Even heavy Datajam users should expect Heroku charges to be less than $10/month.

Once you are set up with Heroku, read through Heroku’s Quickstart Guide to get setup with their tool belt. You need only go through step 3 for our purposes.

Git the code

Now that you've set up your machine with Ruby and Git, and gotten your Heroku account, it's time to download Datajam. We maintain and distribute Datajam's code through GitHub. And in order to move the code from GitHub to your Heroku instance, you must first download the code to your local machine.

There are a number of steps involved in this process, so we've simplified it with one simple shell command:

sh <(curl http://get.datajam.org)

When you run the above command in Terminal, you will be prompted to name the application. Then the script will:

  • download the repository from GitHub
  • create a blank Heroku application
  • install Datajam's software dependencies, such as Ruby on Rails
  • deploy the application to Heroku
  • initialize a database with a default template and admin user account

When the script is finished, you will be given a URL where the code has been installed, along with a username and password. Go ahead and log in to see what you've created.

Configuration

With Datajam installed, it's time to start configuring it for your site. The first step in this process is to manage the templates. We will walk you through the basics of this, but the specifics of your template design will depend on your needs. For example, some users might want to design their installation of Datajam so that it looks just like their website.