Is it possible to use expressions to define the value of a field in director?
I would like to assign a value to overwrite a custom field of type string in a service using an expression like the following:
$field_foo$ ? $field_foo$ : $host.defaultfield$
The idea is, that the field will be defined with the string in field_foo, when field_foo is not empty and host.defaultfield otherwise. The $…$ parts are evaluated with the value of this variables but the defined field does not contain the result of the expresseion but a string like
‘value_of_field_foo ? value_of_field_foo : value _defaultfield’
Any ideas how to get the expression evaluated?