Notification Apply Rules has this note:
*Please use wildcards and the = (equals) operator when searching for partial string matches, like in .example.com
I would like to use a string which contains “=” character in a notification apply rule (e.g. send notifications if a service has “tags” custom variable with “iftype=prod” value). An example:
This example doesn’t work because Icinga converts “service.vars.tags contains iftype=prod” to “prod"=service.vars.tags contains”. I.e. it parses “equal” character as an operator. Any suggestions on how to escape it.
I tried several workarounds, e.g. ASCII character in octal encoding, regex, etc.: “iftype\075prod” in service.vars.tags “iftype\75prod” in service.vars.tags “iftype+prod” in service.vars.tags
*"iftype.prod" in service.vars.tags “iftype\Wprod” in service.vars.tags
It doesn’t work. Icinga doesn’t match “iftype=prod” tag.
It works if I replace “=” with another symbol in service and apply rule (e.g. “iftype:prod”).
Is it possible to escape “=” symbol in notification apply rules? Is this bug?