add logging

This commit is contained in:
KiekerJan 2022-10-15 07:59:25 +02:00
parent 5628c1e674
commit 4914b0c423
1 changed files with 5 additions and 1 deletions

View File

@ -1,7 +1,11 @@
from daemon import app
import auth, utils
import auth, utils, logging
app.logger.addHandler(utils.create_syslog_handler())
logging_level = logging.DEBUG
logging.basicConfig(level=logging_level, format='MiaB %(levelname)s:%(module)s.%(funcName)s %(message)s')
logging.info('Logging level set to %s', logging.getLevelName(logging_level))
if __name__ == "__main__":
app.run(port=10222)