diff --git a/README.md b/README.md index dcbfa1f..e6932ab 100644 --- a/README.md +++ b/README.md @@ -31,3 +31,34 @@ export PYTHONPATH=$(pwd) cd crawl_server python3 server.py ``` +## Running the web server (development) +```bash +cd od-database +python3 app.py +``` + +## Running the web server with nginx (production) +* Install dependencies: +```bash +sudo apt install build-essential python-dev +sudo pip install uwsgi +``` +* Adjust the path in `od-database.ini` +* Configure nginx (on Debian 9: `/etc/nginx/sites-enabled/default`): +```nginx +server { + ... + + include uwsgi_params; + location / { + uwsgi_pass 127.0.0.1:3031; + } + + ... +} +``` +* Start uwsgi: +```bash +uwsgi od-database.ini +``` + diff --git a/scrapy.cfg b/scrapy.cfg deleted file mode 100644 index fdd12f2..0000000 --- a/scrapy.cfg +++ /dev/null @@ -1,12 +0,0 @@ - -[settings] -default = scrapy_od_database.settings - -# Automatically created by: scrapy startproject -# -# For more information about the [deploy] section see: -# https://scrapyd.readthedocs.io/en/latest/deploy.html - -[deploy] -#url = http://localhost:6800/ -project = scrapy_od_database