Merge remote-tracking branch 'key'

This commit is contained in:
Ozzieisaacs 2020-04-30 17:29:41 +02:00
commit e3246fd751

3
cps/__init__.py Executable file → Normal file
View File

@ -89,7 +89,10 @@ def create_app():
log.info('Starting Calibre Web...')
Principal(app)
lm.init_app(app)
if os.environ.get('FLASK_DEBUG'):
app.secret_key = os.getenv('SECRET_KEY', 'A0Zr98j/3yX R~XHH!jmN]LWX/,?RT')
else:
app.secret_key = os.getenv('SECRET_KEY', os.urandom(32))
web_server.init_app(app, config)
db.setup_db(config)