[syslog-ng] Injecting environment variables?

jetjnkr at gmail.com jetjnkr at gmail.com
Thu Sep 18 17:00:58 CEST 2014


New to the list, but looking for some pointers:

It is possible to get shell variables interpreted and defined in the context of the syslog-ng.conf file?


I'm trying to get the value from a shell/environment variable to be added to a logged message.  I've tried various forms of templates in the destination without much success.

template("<$PRI> $DATE $HOST $MSG $someENVvar \n") template_escape(no));

Static text works find, but the var ends up being blank...    

For reasons I won't belabor, I can't use tags as added by the source.  


Apologies if this has been covered previous - I didn't see anything from scanning the archives.

Thanks.
Jim.


More information about the syslog-ng mailing list