File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -616,15 +616,21 @@ def validateCollectorConf(args, logger):
616616
617617def updateCherrypyConf (args ):
618618
619+ path , folder = os .path .split (args .logFile )
620+ if not os .path .exists (path ):
621+ os .makedirs (path )
622+ accesslog = os .path .join (path , 'cherrypy_access.log' )
623+ errorlog = os .path .join (path , 'cherrypy_error.log' )
624+
619625 globalConfig = {
620626 'global' : {
621627 'server.socket_host' : '0.0.0.0' ,
622628 'server.socket_port' : args .port ,
623629 'server.socket_timeout' : 60 , # increase timeout to 60s
624630 'request.show_tracebacks' : False ,
625631 'log.screen' : False , # turn off logging to console
626- 'log.access_file' : "cherrypy_access.log" ,
627- 'log.error_file' : "cherrypy_error.log" ,
632+ 'log.access_file' : accesslog ,
633+ 'log.error_file' : errorlog ,
628634 'tools.encode.on' : True ,
629635 'tools.encode.encoding' : 'utf-8' }}
630636 cherrypy .config .update (globalConfig )
You can’t perform that action at this time.
0 commit comments