mirror of
https://github.com/thatmattlove/hyperglass.git
synced 2026-01-17 00:38:06 +00:00
complete restructure
This commit is contained in:
parent
eb947a7c17
commit
1cc2914c5d
5 changed files with 26 additions and 0 deletions
14
docs/installation/wsgi.md
Normal file
14
docs/installation/wsgi.md
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
For production builds, we'll want to have a real WSGI front end instead of the built in Flask developer web server. For time's sake, Ubuntu 18.04 instructions are provided. That said, this is a pretty generic setup and should be easily replicable to other platforms.
|
||||
|
||||
# Gunicorn Installation
|
||||
|
||||
Gunicorn is a WSGI server written in Python.
|
||||
|
||||
## Install
|
||||
```console
|
||||
# pip3 install gunicorn
|
||||
```
|
||||
|
||||
## Configure
|
||||
|
||||
Locate your `gunicorn` executable with `which gunicorn`
|
||||
7
hyperglass/config/gunicorn_config.py
Normal file
7
hyperglass/config/gunicorn_config.py
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
import multiprocessing
|
||||
|
||||
command = "/usr/local/bin/gunicorn"
|
||||
pythonpath = "/opt/hyperglass/hyperglass"
|
||||
bind = "[::1]:8001"
|
||||
workers = multiprocessing.cpu_count() * 2
|
||||
user = "www-data"
|
||||
4
hyperglass/wsgi.py
Normal file
4
hyperglass/wsgi.py
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
import app
|
||||
|
||||
if __name__ == "__main__":
|
||||
app.run()
|
||||
|
|
@ -18,6 +18,7 @@ nav:
|
|||
- 'Commands': 'configuration/commands.md'
|
||||
- 'Proxy': 'configuration/proxy.md'
|
||||
- 'Blacklist': 'configuration/blacklist.md'
|
||||
- 'Securing Router Access': 'configuration/securing-router-access.md'
|
||||
- Caching:
|
||||
- 'caching.md'
|
||||
- Rate Limiting:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue