Created
March 7, 2014 18:05
-
-
Save mmahesh/9416628 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Views | |
import logging | |
logger = logging.getLogger(__name__) | |
# Settings | |
LOGGING = { | |
'version': 1, | |
'disable_existing_loggers': False, | |
'formatters': { | |
'simple': { | |
'format': '%(asctime)s SENDER_NAME PROGRAM_NAME: %(message)s', | |
'datefmt': '%b %d %H:%M:%S', | |
}, | |
}, | |
'handlers': { | |
'SysLog':{ | |
'level':'DEBUG', | |
'class':'logging.handlers.SysLogHandler', | |
'formatter': 'simple', | |
'address':('localhost', 514) | |
} | |
}, | |
'loggers': { | |
'django.request': { | |
'handlers': ['SysLog'], | |
'level': 'DEBUG', | |
'propagate': True, | |
}, | |
'auth.views': { | |
'handlers': ['SysLog'], | |
'level': 'DEBUG', | |
'propagate': True, | |
}, | |
}, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment