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):
616
616
617
617
def updateCherrypyConf (args ):
618
618
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
+
619
625
globalConfig = {
620
626
'global' : {
621
627
'server.socket_host' : '0.0.0.0' ,
622
628
'server.socket_port' : args .port ,
623
629
'server.socket_timeout' : 60 , # increase timeout to 60s
624
630
'request.show_tracebacks' : False ,
625
631
'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 ,
628
634
'tools.encode.on' : True ,
629
635
'tools.encode.encoding' : 'utf-8' }}
630
636
cherrypy .config .update (globalConfig )
You can’t perform that action at this time.
0 commit comments