parent
6498e1fe87
commit
752d05dedb
1 changed files with 9 additions and 0 deletions
|
@ -2,6 +2,7 @@ import logging
|
|||
import os
|
||||
import features
|
||||
import time
|
||||
import socket
|
||||
|
||||
from app import app, userfiles as user_files, build_logs, dockerfile_build_queue
|
||||
|
||||
|
@ -10,6 +11,8 @@ from buildman.manager.ephemeral import EphemeralBuilderManager
|
|||
from buildman.server import BuilderServer
|
||||
|
||||
from trollius import SSLContext
|
||||
from raven.handlers.logging import SentryHandler
|
||||
from raven.conf import setup_logging
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
@ -77,4 +80,10 @@ if __name__ == '__main__':
|
|||
logging.basicConfig(level=logging.DEBUG, format=LOG_FORMAT)
|
||||
logging.getLogger('peewee').setLevel(logging.WARN)
|
||||
logging.getLogger('boto').setLevel(logging.WARN)
|
||||
|
||||
if app.config.get('EXCEPTION_LOG_TYPE', 'FakeSentry') == 'Sentry':
|
||||
buildman_name = '%s:buildman' % socket.gethostname()
|
||||
setup_logging(SentryHandler(app.config.get('SENTRY_DSN', ''), name=buildman_name,
|
||||
level=logging.ERROR))
|
||||
|
||||
run_build_manager()
|
||||
|
|
Reference in a new issue