The backend can be run inside a docker container for testing purposes.
To build and start backend with database to be stored in your ~/ksi-be
execute ./.docker/build.sh --run ~/ksi-db ~/ksi-data
.
Already built docker images can be started by running ./.docker/start.sh ~/ksi-db ~/ksi-data
or docker start -i ksi-be
if it was started at least one time before.
Though most of the API works out-of-the box, it is possible that you will run into unexpected errors. If so, please create Issue with report and reproduction steps.
requirements.txt
init-makedirs.sh
.ksi-py3-venv
directory.
virtualenv -p python3 ksi-py3-venv
source ksi-py3-venv/bin/activate
pip3 install -r requirements.txt
config.py
file. Format is the same as specified in config.py.dist
app.py
, which creates database structure.run.py
isolate
with box directory /tmp/box
./etc
directory to /opt/etc
(this is required for sandbox to
work):
$ mount --bind /etc /opt/etc
Do not forget to add it to /etc/fstab
.
/tmp
tmpfs../runner start
)../runner start
../runner stop
.runner
script must be executed in server`s root directory./var/log/gunicorn/*
.