THIS PROJECT IS NOW UNMAINTAINED.
The current repository where this project lives on is here: https://github.com/release-engineering/resultsdb
ResultsDB is a results store engine for (not only) Fedora QA tools. The API documentation can be found at http://docs.resultsdb20.apiary.io/.
First, clone the repository.
Then, setup a virtual environment for development:
$ sudo dnf install python-virtualenv python-pip $ virtualenv --system-site-packages env_resultsdb $ source env_resultsdb/bin/activate $ pip install -r requirements.txt
If you encounter any installation issues, it's possible that you don't have
gcc and necessary C development headers installed to compile C extensions
from PyPI. Either install those based on the error messages, or install
the necessary packages directly to your system. See
Install the project:
$ python setup.py develop
Initialize your database:
$ DEV=true ./init_db.sh
Run the server:
$ DEV=true python runapp.py
You can configure this app by copying
conf/setting.py and adjusting values as you see fit. It overrides default
You might want to use this tool together with libtaskotron. To use your own
ResultsDB server in libtaskotron, edit
set the following value::
You might also need to adjust
depending on your local settings.
Sometimes, you might want to check some performance tweaks with real-life data. The easy solution might be using our daily dumps and a Postgres instance in Docker::
docker run --name postgres_resultsdb -e POSTGRES_USER=resultsdb -e POSTGRES_PASSWORD=resultsdb -d -p 65432:5432 postgres wget https://infrastructure.fedoraproject.org/infra/db-dumps/resultsdb.dump.xz xzcat resultsdb.dump.xz | docker exec -i postgres_resultsdb psql -Uresultsdb
Then just change your config (for DEV environment, you can use
to contain this db connector::
SQLALCHEMY_DATABASE_URI = 'postgresql+psycopg2://resultsdb:resultsdb@localhost:65432/resultsdb'
And run as usual.
You can run the test suite with the following command::
Note, that in order for some of the tests to work properly, tox is configured to spin-up PostgreSQL in a docker container using the
tox-docker plugin, which needs to be installed separately. The best option probably is::
$ pip install --user tox-docker $ pip3 install --user tox-docker
Should you, for some reason avoid docker, you could run the following command (with virtualenv active)::
$ NO_CAN_HAS_POSTGRES=sadly pytest
To use tox-docker with podman without requiring root, you can use
tox-podman.sh script that wraps
$ ./tox-podman.sh -e py39
If you're trying to deploy ResultsDB, you might find some helpful instructions in the Fedora infra docs.