Sha256: 9c9f443707d6bb350b681e92db99fa5010d5e47a5cfe361a9ae48f3fd18e9c7a
Contents?: true
Size: 376 Bytes
Versions: 55
Compression:
Stored size: 376 Bytes
Contents
#!/usr/bin/perl # argument 1 = facility (i.e. local7) # argument 2 = program (i.e. apache) # argument 3 = log_level (i.e. notice) if ((@ARGV + 0) < 3) { print "usage $0 <facility> <program> <log_level>" ; } use Sys::Syslog qw( :DEFAULT setlogsock ); setlogsock('unix'); openlog($ARGV[1], 'pid', $ARGV[0]); while ($log = <STDIN>) { syslog($ARGV[2], $log); } closelog
Version data entries
55 entries across 55 versions & 1 rubygems