log.conf 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. ########################################
  2. # Definition for the different objects
  3. # - FOR DEVELOPMENT ONLY -
  4. #
  5. # Directories where log files are kept must already exist.
  6. # That's why we pick /tmp.
  7. #
  8. # The loggers are configured to write to the log files ONLY.
  9. # Developers may set the DESKTOP_DEBUG environment variable to
  10. # enable stderr logging output.
  11. ########################################
  12. [logger_root]
  13. handlers=logfile,errorlog
  14. [logger_access]
  15. handlers=accesslog
  16. qualname=access
  17. [logger_django_auth_ldap]
  18. handlers=accesslog
  19. qualname=django_auth_ldap
  20. [logger_kazoo_client]
  21. level=INFO
  22. handlers=errorlog
  23. qualname=kazoo.client
  24. [handler_stderr]
  25. class=StreamHandler
  26. formatter=default
  27. level=DEBUG
  28. args=(sys.stderr,)
  29. [handler_accesslog]
  30. class=handlers.RotatingFileHandler
  31. level=INFO
  32. propagate=True
  33. formatter=access
  34. args=('%LOG_DIR%/access.log', 'a', 1000000, 3)
  35. [handler_errorlog]
  36. class=handlers.RotatingFileHandler
  37. level=ERROR
  38. formatter=default
  39. args=('%LOG_DIR%/error.log', 'a', 1000000, 3)
  40. [handler_logfile]
  41. class=handlers.RotatingFileHandler
  42. # Choices are DEBUG, INFO, WARNING, ERROR, CRITICAL
  43. level=DEBUG
  44. formatter=default
  45. args=('%LOG_DIR%/%PROC_NAME%.log', 'a', 1000000, 3)
  46. [formatter_default]
  47. class=desktop.log.formatter.Formatter
  48. format=[%(asctime)s] %(module)-12s %(levelname)-8s %(message)s
  49. datefmt=%d/%b/%Y %H:%M:%S %z
  50. [formatter_access]
  51. class=desktop.log.formatter.Formatter
  52. format=[%(asctime)s] %(levelname)-8s %(message)s
  53. datefmt=%d/%b/%Y %H:%M:%S %z
  54. ########################################
  55. # A summary of loggers, handlers and formatters
  56. ########################################
  57. [loggers]
  58. keys=root,access,django_auth_ldap,kazoo_client
  59. [handlers]
  60. keys=stderr,logfile,accesslog,errorlog
  61. [formatters]
  62. keys=default,access