Skip to content

Commit

Permalink
Fix documentation.
Browse files Browse the repository at this point in the history
[git-p4: depot-paths = "//src/SyslogLogger/dev/": change = 3159]
  • Loading branch information
drbrain committed May 9, 2007
1 parent 9fc4132 commit 3d7d496
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 7 deletions.
4 changes: 3 additions & 1 deletion History.txt
@@ -1,5 +1,7 @@
== 1.4.0 / 2007-04-21
== 1.4.0 / 2007-05-08

* Split from rails_analyzer_tools.
* Added eh methods for compatibility with Logger.
* Added syslog-ng instructions. Patch by Tom Lianza.
* Fixed require in documentation. Reported by Gianni Jacklone.

24 changes: 18 additions & 6 deletions lib/syslog_logger.rb
Expand Up @@ -11,17 +11,17 @@
#
# NOTE! You can only set the SyslogLogger program name when you initialize
# SyslogLogger for the first time. This is a limitation of the way
# SyslogLogger uses syslog (and in some ways, a the way syslog(3) works).
# Attempts to change SyslogLogger's program name after the first
# initialization will be ignored.
# SyslogLogger uses syslog (and in some ways, a limitation of the way
# syslog(3) works). Attempts to change SyslogLogger's program name after the
# first initialization will be ignored.
#
# = Sample usage with Rails
#
# == config/environment/production.rb
#
# Add the following lines:
#
# require 'production_log/syslog_logger'
# require 'syslog_logger'
# RAILS_DEFAULT_LOGGER = SyslogLogger.new
#
# == config/environment.rb
Expand All @@ -36,7 +36,9 @@
#
# Other versions of Rails should have a similar change.
#
# == /etc/syslog.conf
# == BSD syslog setup
#
# === /etc/syslog.conf
#
# Add the following lines:
#
Expand All @@ -46,7 +48,7 @@
# Then touch /var/log/production.log and signal syslogd with a HUP
# (killall -HUP syslogd, on FreeBSD).
#
# == /etc/newsyslog.conf
# === /etc/newsyslog.conf
#
# Add the following line:
#
Expand All @@ -55,6 +57,16 @@
# This creates a log file that is rotated every day at midnight, gzip'd, then
# kept for 7 days. Consult newsyslog.conf(5) for more details.
#
# == syslog-ng setup
#
# === syslog-ng.conf
#
# destination rails_log { file("/var/log/production.log"); };
# filter f_rails { program("rails.*"); };
# log { source(src); filter(f_rails); destination(rails_log); };
#
# == Starting
#
# Now restart your Rails app. Your production logs should now be showing up
# in /var/log/production.log. If you have mulitple machines, you can log them
# all to a central machine with remote syslog logging for analysis. Consult
Expand Down

0 comments on commit 3d7d496

Please sign in to comment.