doorlockd.py: switch to config file

Signed-off-by: Ralf Ramsauer <ralf@binary-kitchen.de>
This commit is contained in:
Ralf Ramsauer 2018-03-18 16:15:48 +01:00
parent ae0d4f5aa2
commit a21beefe74
2 changed files with 3 additions and 1 deletions

2
doorlockd-new/config.cfg Normal file
View File

@ -0,0 +1,2 @@
DEBUG = True
SECRET_KEY = 'foobar'

View File

@ -39,7 +39,7 @@ default_binddn = 'cn=%s,ou=people,dc=binary-kitchen,dc=de'
html_title = 'Binary Kitchen Doorlock (%s - v%s)' % (__status__, __version__)
webapp = Flask(__name__)
webapp.config['SECRET_KEY'] = 'foobar'
webapp.config.from_pyfile('config.cfg')
socketio = SocketIO(webapp, async_mode=None)
Bootstrap(webapp)