Home

Awesome

Champaign

Circle CI Coverage Status Code Climate

Champaign is an open source digital campaigning platform built by SumOfUs. It's designed to streamline campaigner workflows creating and iterating on pages, while also providing tools for deep customization of layouts and functionality, all through the web interface. At it's core, Champaign is a CMS to easily create petitions, fundraisers, social-media shares, and surveys, and to record member responses to these action pages. It is also designed to be extensible, allowing developers to contribute new page functionality.

Champaign is also designed with a focus on performance, reliability, maintainability.

This is the second digital campaigning CMS developed under direction SumOfUs. The previous system, ActionSweet, still powers several other digital campaigning organizations. Champaign was designed to specifically alleviate issues present in ActionSweet and manifests the lessons learned over 5 years of running online campaigns.

If you're interested in collaborating on the project with us, or have ideas or recommendations, please get in touch!

Development setup

Champaign Configuration

Configuration files are under config/settings directory. There's one config file per environment: production, test and development. All keys defined in these YAML files will be accessible via Settings.option_name.

You can override configuration variables during development by creating a config/settings/development.local.yml file.

Vendor theme and overrides

Champaign is a full Rails app. While it's ready to be deployed out of the box, you will likely want to customise its styles, images, and translations. To that end,Champaign has a vendor/theme folder where you can add, override, or customise translation strings, layouts/partials, and images.

ActionKit Integration

Champaign integrates seamlessly with ActionKit. The integration works via events that are triggered from Champaign and are then captured by a separate service: champaign-ak-processor, which in turn updates ActionKit via its API. Champaign events are delivered using AWS SQS.

Despite having this external service to communicate with ActionKit, Champaign still needs to access ActionKit's API directly in a couple of cases, that's why you'll need to configure AK credentials in order to run Champaign. You'll be able to do this using environment variables in production, or overriding the proper keys in config/settings.development.local.yml for development.

Braintree & GoCardless integration

Champaign accepts donations by integrating with Braintree for credit card, debit card, and Paypal payments, and GoCardless for direct debit. To get these integrations working you'll have to setup the proper credentials by setting environment variables on your production environment.

If you use a separate endpoint to fetch your Braintree tokens, you can point to it by updating the env.yml with your BRAINTREE_TOKEN_URL. By default, Champaign will use its own token endpoint which could degrade performance, so it's recommended that you use a separate service where possible.

Development Setup using Docker

You can run the required Postgres and Redis databases on Docker using docker-compose. We suggest you run the Rails application on host since the default Dockerfile is a production file missing some test / development dependencies.

Simply install Docker and Compose, and issue docker-compose up to run your redis and postgres database. Port mapping will map the container ports to the databases' expected (default) ports on host.