codeforamerica / cityvoice-survey-builder

Deploy an instance of CityVoice to Heroku without ever leaving the comfort of your web browser
https://cityvoice-setup.codeforamerica.org
6 stars 4 forks source link

CityVoice Survey Builder

Running Locally

Testing

Test the builder with RSpec:

rspec

Deployment

Non-CFA users shouldn't need to deploy this, but for documentation purposes, here goes!

First, go to your account page on Heroku and under 'API Clients' click the 'Register API Client' button.

There, set the Name (whatever you want) and the OAuth Callback URL (this will be /callback on your deployment, for example: https://my-cityvoice-builder-instance.herokuapp.com/callback )

Once you've done that, note the 'ID' and 'SECRET' it gives you.

Now, clone this repo and cd into the folder. From there, create a Heroku app with your own name and the multi buildpack:

$ heroku create --buildpack https://github.com/ddollar/heroku-buildpack-multi.git my-cityvoice-builder-name

Now, configure your Builder app with the ID and SECRET from above:

$ heroku config:set HEROKU_OAUTH_ID=lolmyoauthid
$ heroku config:set HEROKU_OAUTH_SECRET=lolmysecret

Now push!

$ git push heroku master

Lastly, provision Heroku's RedisToGo add-on:

$ heroku addons:add redistogo:small

(Details and pricing [$39/mo for the small add-on shown above] can be found at: https://addons.heroku.com/RedisToGo )

Copyright Code for America Labs 2014, MIT License