Hack The Printer Scoring Panel
This scoring panel was coded in a histerical rush, so its quality is quite low... But, it works! It simply displays a pretty scoring board for the Hack The Printer event in ekoparty13. You need to populate the database through Django Admin Panel, or directly to the chosen DB.
How to use
For developing or testing
Download a release or clone the repo and then, inside your virtual environment, run:
cd eko-panel pip install -r requirements cd eko cp eko/settings.py.dist eko/settings.py # Edit settings accordingly (change the secret key, disable debug, set static path, etc.) vim eko/settings.py ./manage.py collectstatic ./manage.py check ./manage.py makemigrations ./manage.py migrate # Run dev server ./manage.py runserver
For a production server
NGINX + uWSGI + Django is the best combination. Check this project to create a Docker container: https://github.com/dockerfiles/django-uwsgi-nginx. In the deploy directory there are some example config files. Just copy that directory to the server, then copy eko project dir into app/ and change the settings accordingly:
SECRET_KEYfor a long random value, such as:
read -r -n 100 SECRET_KEY < <(LC_ALL=C tr -dc 'A-Za-z0-9_\-.,;:?/"[}]}|=+)(*&^%$#!@~' < /dev/urandom) && echo $SECRET_KEY(note than some characters where left out).
- disable debug mode! set
DEBUG = False.
STATIC_ROOT = '/home/docker/volatile/static'(if you didn't changed any path).
- change any other security related variable.
Finally, simply run:
docker build -t hacktheprinter . docker run -d -p 80:80 hacktheprinter
There's also a simple script,
deploy.bash that does that, quick and ugly. READ IT FIRST! Don't blindly execute it.
"Hack The Printer" logo by Andres Snitcofsky, under WTFPL. Template design by A Fox, under WTFPL.