third-party-ci-tools/monitoring/scoreboard/db_helper.py
Patrick East c0d0d4cac8 Import ci scoreboard tool.
This is a simple set of scripts that can listen to gerrit, track 3rd
party ci systems reviews, and display a web dashboard showing their
results.

A demo system can be found here:

http://ec2-54-67-102-119.us-west-1.compute.amazonaws.com:5000/?project
=openstack%2Fcinder&user=&timeframe=24

It is not intended to do much more than just show success/fail, and can
work nicely as a quick way to compare your systems results with others
to catch any issues you might be having.

Change-Id: I682c5426fe834a63d3e4f27ebde7d40ee7f9749b
2015-05-11 13:40:20 -07:00

11 lines
224 B
Python

import pymongo
class DBHelper:
def __init__(self, config):
self._mongo_client = pymongo.MongoClient(config.db_uri())
self._db = self._mongo_client.scoreboard
def get(self):
return self._db