Skip to content

classify/custom-functions

Add custom templates to the Classifier (presumably additional match Functions)

Use this Param to specify additional custom templates to include in to the Classifier.

This is intended to inject BASH "function NAME { ... }" stanzas in the classifer to provide custom function blocks to extend the tests and/or actions you can apply to the classifier.

YAML Example

- "my-classify-function-1.tmpl"
- "my-classify-function-2.tmpl"

JSON Example

[
  "my-classify-function-1.tmpl",
  "my-classify-function-2.tmpl"
]

Note

The executing environment is Sledgehammer with BASH scripts. You must ensure that the Function you inject operates correctly in this environment. For reference, see the Functions in the existing classifier Template classify.sh.tmpl.

Any test functions should echo "pass" or echo "fail" to signal the test condition status and should subsequently apply the given actions specified.

An example template named has_inventory_value.tmpl has been provided that the operator can use as an example test condition.

Objects that Reference classify/custom-functions

Not used in current content packs

Objects used by classify/custom-functions

Not used in current content packs