~ajk/idpa-results

69bd78a2 — Andrew Kay 2 years ago
Updating documentation
6f60ae23 — Andrew Kay 2 years ago
Adding gunicorn to Heroku requirements - got missed in previous upgrade
72ccf050 — Andrew Kay 2 years ago
Implementing 2017 total time calculation

refs

master
browse  log 

clone

read-only
https://git.sr.ht/~ajk/idpa-results
read/write
git@git.sr.ht:~ajk/idpa-results

You can also use your local clone with git send-email.

#idpa-results

A simple tool for viewing IDPA results.

#Installation

#Local

git clone https://bitbucket.org/ajk/idpa-results.git

cd idpa-results

python -m venv VIRTUALENV
. VIRTUALENV/bin/activate

pip install -r requirements/not-heroku.txt

createdb idpa-results
psql -f create.sql idpa-results

#Heroku

git clone --origin bitbucket https://bitbucket.org/ajk/idpa-results.git

heroku apps:create idpa-results -b https://github.com/kennethreitz/conda-buildpack.git --addons heroku-postgresql

heroku config:add FLASK_SECRET_KEY TOPSECRET
heroku config:add WELCOME_MESSAGE_URL=1:https://bitbucket.org/\!api/2.0/snippets/ajk/yqd7M/0acf739f8f4a89125496db3edbbb9958907d873b/files/welcome.md
heroku config:add HELP_CONTENT_URL=https://bitbucket.org/\!api/2.0/snippets/ajk/yqd7M/0acf739f8f4a89125496db3edbbb9958907d873b/files/help.md

cat create.sql | heroku pg:psql

git push heroku master

#Usage

#Start web application

. VIRTUALENV/bin/activate

flask run
#Environment variables
Variable Example Description
DATABASE_URL postgresql:///idpa-results Database connection
FLASK_SECRET_KEY TOPSECRET Flask secret key
WELCOME_MESSAGE_URL 1:http://example.com/welcome.md Optional welcome message key and resource URL
HELP_CONTENT_URL http://example.com/help.md Optional help content URL

#Loading results

. VIRTUALENV/bin/activate

export DATABASE_URL=postgresql:///idpa-results

./katerina.py 123456

#License

See UNLICENSE.