Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-06 Thread deoren
On 3/6/2018 2:53 AM, Rainer Gerhards wrote: 2018-03-06 9:04 GMT+01:00 deoren : On 3/6/2018 1:43 AM, Rainer Gerhards wrote: 2018-03-05 19:17 GMT+01:00 deoren : Hi, When refactoring an older

Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-06 Thread Rainer Gerhards
2018-03-06 9:04 GMT+01:00 deoren : > On 3/6/2018 1:43 AM, Rainer Gerhards wrote: >> >> 2018-03-05 19:17 GMT+01:00 deoren >> : >>> >>> Hi, >>> >>> When refactoring an older configuration I figured I would

Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-06 Thread deoren
On 3/6/2018 1:43 AM, Rainer Gerhards wrote: 2018-03-05 19:17 GMT+01:00 deoren : Hi, When refactoring an older configuration I figured I would give global variables a try. I'm attempting to create a generic email notification ruleset that can be

Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-05 Thread Rainer Gerhards
2018-03-05 19:17 GMT+01:00 deoren : > Hi, > > When refactoring an older configuration I figured I would give global > variables a try. > > I'm attempting to create a generic email notification ruleset that can be > called after setting values in a

Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-05 Thread deoren
On 3/5/2018 7:48 PM, David Lang wrote: On Mon, 5 Mar 2018, deoren wrote: if $.email-notification!sender == '' then {    $.email-notification!sender = $/default-email-notification!sender; This needs to be set $.email-notification!sender = $/default-email-notification!sender; (you forgot

Re: [rsyslog] What is the syntax for comparing a global variable against a local variable?

2018-03-05 Thread David Lang
On Mon, 5 Mar 2018, deoren wrote: if $.email-notification!sender == '' then { $.email-notification!sender = $/default-email-notification!sender; This needs to be set $.email-notification!sender = $/default-email-notification!sender; (you forgot the 'set')