[ckan-dev] file logging in CKAN

Hildegard Gerlach hildegard.gerlach at jrc.ec.europa.eu
Wed Feb 19 09:50:23 UTC 2014


Hello,

I am using the following configuration in my CKAN development.ini 
configuration file for the extensions:

[logger_ckanext]
level = DEBUG
#level = INFO
handlers = filelog_ext
qualname = ckanext
propagate = 0

[handler_filelog_ext]
class = logging.handlers.RotatingFileHandler
args = ("/var/log/ckan/ckan_ext.log", "a", 20000000, 9,)
level = NOTSET
formatter = generic

Every time the log file is rotated, it is created with permission 644. 
When I do harvesting from CKAN however, apache wants to write to this 
file and I get a permission error and have to set the permission 
manually. Is there a way to change this without having to rewrite the 
Python log handler ?

Thanks

Hilde



More information about the ckan-dev mailing list