Spaces:
Runtime error
Runtime error
imperialwool
commited on
Commit
•
73fd428
1
Parent(s):
5000d91
waitress update
Browse files- app.py +4 -1
- requirements.txt +2 -0
- routes/config.json +1 -1
app.py
CHANGED
@@ -1,5 +1,7 @@
|
|
1 |
import os
|
2 |
from flask import *
|
|
|
|
|
3 |
|
4 |
from routes.helpers import configFile
|
5 |
from routes import *
|
@@ -105,4 +107,5 @@ if __name__ == "__main__":
|
|
105 |
outfile.write(info.replace('$VERSION_VARIABLE$', VERSION))
|
106 |
outfile.truncate()
|
107 |
|
108 |
-
|
|
|
|
1 |
import os
|
2 |
from flask import *
|
3 |
+
from waitress import serve
|
4 |
+
from paste.translogger import TransLogger
|
5 |
|
6 |
from routes.helpers import configFile
|
7 |
from routes import *
|
|
|
107 |
outfile.write(info.replace('$VERSION_VARIABLE$', VERSION))
|
108 |
outfile.truncate()
|
109 |
|
110 |
+
# $VERSION_VARIABLE$
|
111 |
+
serve(TransLogger(app, setup_console_handler=False), host="0.0.0.0", port=7860, threads=4, ident="FunAPI", )
|
requirements.txt
CHANGED
@@ -4,5 +4,7 @@ Pillow
|
|
4 |
psutil
|
5 |
urllib3
|
6 |
requests
|
|
|
7 |
py-cpuinfo
|
|
|
8 |
ffmpeg-python
|
|
|
4 |
psutil
|
5 |
urllib3
|
6 |
requests
|
7 |
+
waitress
|
8 |
py-cpuinfo
|
9 |
+
PasteDeploy
|
10 |
ffmpeg-python
|
routes/config.json
CHANGED
@@ -9,5 +9,5 @@
|
|
9 |
"config-path": "./routes/config.json",
|
10 |
"openapi-yaml-path": "./static/api.yaml",
|
11 |
|
12 |
-
"buildVersion": "1.0
|
13 |
}
|
|
|
9 |
"config-path": "./routes/config.json",
|
10 |
"openapi-yaml-path": "./static/api.yaml",
|
11 |
|
12 |
+
"buildVersion": "1.0 commit157"
|
13 |
}
|