[Zope-Checkins] CVS: Zope - z2.py:1.60

Toby Dickenson tdickenson@geminidataloggers.com
Mon, 11 Mar 2002 08:44:18 -0500


Update of /cvs-repository/Zope
In directory cvs.zope.org:/tmp/cvs-serv17281

Modified Files:
	z2.py 
Log Message:
merged toby-syslog-access-branch: Collector 271: use different environment variables for sending event log and access log to syslog

=== Zope/z2.py 1.59 => 1.60 ===
     if READ_ONLY:
         lg = logger.file_logger('-') # log to stdout
-    elif os.environ.has_key('ZSYSLOG'):
-        lg = logger.syslog_logger(os.environ['ZSYSLOG'])
-        if os.environ.has_key("ZSYSLOG_FACILITY"):
-            lg = logger.syslog_logger(os.environ['ZSYSLOG'],facility=os.environ['ZSYSLOG_FACILITY'])
+    elif os.environ.has_key('ZSYSLOG_ACCESS'):
+        if os.environ.has_key("ZSYSLOG_ACCESS_FACILITY"):
+            lg = logger.syslog_logger(os.environ['ZSYSLOG_ACCESS'],facility=os.environ['ZSYSLOG_ACCESS_FACILITY'])
         else:
-            lg = logger.syslog_logger(os.environ['ZSYSLOG'])
-    elif os.environ.has_key('ZSYSLOG_SERVER'):
-        (addr, port) = os.environ['ZSYSLOG_SERVER'].split( ':')
+            lg = logger.syslog_logger(os.environ['ZSYSLOG_ACCESS'])
+    elif os.environ.has_key('ZSYSLOG_ACCESS_SERVER'):
+        (addr, port) = os.environ['ZSYSLOG_ACCESS_SERVER'].split( ':')
         lg = logger.syslog_logger((addr, int(port)))
     else:
         lg = logger.file_logger(LOG_PATH)