[syslog-ng]Templates

Achim Gsell syslog-ng@lists.balabit.hu
Mon, 24 Feb 2003 23:29:05 +0100


On Monday 24 February 2003 20:15, Richard E. Perlotto II wrote:
> With the new version being available, are there any
> documents on the new capabilities for templates and
> such?

Not yet, it's still missing (even in the snapshot syslog-ng-1.6rc1+20030224). 
But the "new capabilities for templates" are the implementation of the well 
known "template()" and "template_escape()" options of the "file" destination 
driver to all other destination drivers. The syntax is the same. Thus you can 
define destination drivers like


destination d_net {
        tcp( "loghost" port(10514)
                template("$ISODATE $HOST $MSG\n")
                template_escape(yes)
        );
};

destination d_user {
        usertty("achim"
                template("$ISODATE $HOST [$FACILITY.$LEVEL] $MSG\n")
                template_escape(yes)
        );
};

etc ....


Achim