CC-4032: pyponotify.py fails because not all files in /var/log/airtime/pypo are read/writable by pypo

-fixed
This commit is contained in:
Martin Konecny 2012-06-28 17:09:41 -04:00
parent dd098d47fa
commit 13fb3a02c5
3 changed files with 31 additions and 15 deletions

View File

@ -1,8 +1,8 @@
[loggers]
keys=root,fetch,push,recorder,message_h,notify
keys=root,fetch,push,recorder,message_h
[handlers]
keys=pypo,recorder,message_h,notify
keys=pypo,recorder,message_h
[formatters]
keys=simpleFormatter
@ -35,18 +35,6 @@ handlers=message_h
qualname=message_h
propagate=0
[logger_notify]
level=DEBUG
handlers=notify
qualname=notify
propagate=0
[handler_notify]
class=logging.handlers.RotatingFileHandler
level=DEBUG
formatter=simpleFormatter
args=("/var/log/airtime/pypo/notify.log", 'a', 1000000, 5,)
[handler_pypo]
class=logging.handlers.RotatingFileHandler
level=DEBUG

View File

@ -0,0 +1,28 @@
[loggers]
keys=root,notify
[handlers]
keys=notify
[formatters]
keys=simpleFormatter
[logger_root]
level=DEBUG
handlers=pypo
[logger_notify]
level=DEBUG
handlers=notify
qualname=notify
propagate=0
[handler_notify]
class=logging.handlers.RotatingFileHandler
level=DEBUG
formatter=simpleFormatter
args=("/var/log/airtime/pypo/notify.log", 'a', 1000000, 5,)
[formatter_simpleFormatter]
format=%(asctime)s %(levelname)s - [%(filename)s : %(funcName)s() : line %(lineno)d] - %(message)s
datefmt=

View File

@ -46,7 +46,7 @@ parser.add_option("-y", "--source-status", help="source connection stauts", meta
(options, args) = parser.parse_args()
# configure logging
logging.config.fileConfig("logging.cfg")
logging.config.fileConfig("notify_logging.cfg")
logger = logging.getLogger('notify')
LogWriter.override_std_err(logger)