include config
This commit is contained in:
11
code/start_app.py
Normal file
11
code/start_app.py
Normal file
@@ -0,0 +1,11 @@
|
||||
import subprocess,json
|
||||
|
||||
config = json.load(open('data/config.json','rt'))
|
||||
|
||||
subprocess.call([
|
||||
'gunicorn',
|
||||
'-b','0.0.0.0:80',
|
||||
'--timeout',str(config['timeout']),
|
||||
'-w',str(config['workers']),
|
||||
'app:app'
|
||||
])
|
||||
8
data/config.json
Normal file
8
data/config.json
Normal file
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"workers": 8,
|
||||
"timeout": 3600,
|
||||
"uid": 1000,
|
||||
"data_folder": "data",
|
||||
"shares_file": "data/shares.json",
|
||||
"date_format": "%Y-%m-%d %H:%M"
|
||||
}
|
||||
Reference in New Issue
Block a user