mirror of
https://github.com/simon987/od-database.git
synced 2025-04-20 02:46:45 +00:00
Updated README with web server information
This commit is contained in:
parent
2b83698292
commit
123f38e65d
31
README.md
31
README.md
@ -31,3 +31,34 @@ export PYTHONPATH=$(pwd)
|
|||||||
cd crawl_server
|
cd crawl_server
|
||||||
python3 server.py
|
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
|
||||||
|
```
|
||||||
|
|
||||||
|
12
scrapy.cfg
12
scrapy.cfg
@ -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
|
|
Loading…
x
Reference in New Issue
Block a user