Move site.debug to _dev, _prod launchers.
This commit is contained in:
parent
481a16b950
commit
5bedabdc66
2 changed files with 6 additions and 1 deletions
|
@ -21,9 +21,11 @@ from voussoirkit import vlogging
|
|||
|
||||
import bot
|
||||
import ycdl
|
||||
|
||||
import backend
|
||||
|
||||
site = backend.site
|
||||
site.debug = True
|
||||
|
||||
####################################################################################################
|
||||
|
||||
site = backend.site
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
'''
|
||||
This file is the WSGI entrypoint for remote / production use.
|
||||
Note that YCDL currenty features no authentication, so using it remotely without
|
||||
another kind of access control is probably a bad idea!
|
||||
|
||||
If you are using Gunicorn, for example:
|
||||
gunicorn ycdl_flask_prod:site --bind "0.0.0.0:PORT" --access-logfile "-"
|
||||
|
@ -14,6 +16,7 @@ import backend
|
|||
backend.site.wsgi_app = werkzeug.middleware.proxy_fix.ProxyFix(backend.site.wsgi_app)
|
||||
|
||||
site = backend.site
|
||||
site.debug = False
|
||||
|
||||
# NOTE: Consider adding a local .json config file.
|
||||
youtube_core = ycdl.ytapi.Youtube(bot.get_youtube_key())
|
||||
|
|
Loading…
Reference in a new issue