Use the Sample Rule and Playbook Configurations for BYOI Custom Plug-ins
Before you configure a custom rule, playbook, and device group for the Bring Your Own Ingest (BYOI) custom plug-in, you must create an instance of the custom plug-in. See Configure Bring Your Own Ingest Custom Plug-in Instances for more information.
You must write your own rules for custom Bring Your Own Ingest plug-ins. You must deploy a custom rule in a new playbook that you create for the BYOI plug-in ingest. You must also create a new device group that you add later in the BYOI playbook. Enter the rule and playbook configurations in Paragon Insights management CLI.
The following sample rule triggers an alert when value of key is greater than 5. The trigger alert frequency is set to 10 seconds.
set healthbot topic external rule r1 sensorsensor_a byoi plugin name example-plug-in set healthbot topic external rule r1 field key sensor sensor_a path key set healthbot topic external rule r1 field key type integer set healthbot topic external rule r1 trigger trigger_789 frequency 10s set healthbot topic external rule r1 trigger trigger_789 term Term_1 when greater-than "$key" 5 set healthbot topic external rule r1 trigger trigger_789 term Term_1 then status color red set healthbot topic external rule r1 trigger trigger_789 term Term_1 then status message BAD set healthbot topic external rule r1 trigger trigger_789 disable-alarm-deduplication
The example-plug-in in the sample rule refers to the plug-in name you entered in the Name field, when creating an instance of the custom plug-in.
The sensor_a in the sample rule refers to the value configured for the key parameter in the Value field, when creating an instance of the custom plug-in.
Use the following sample command to create a playbook p1 for the BYOI ingest that uses the sample rule r1 that you previously configured.
set healthbot playbook p1 rules external/r1
After you deploy the playbook configuration, you must create a new instance of the playbook in the Playbooks page. Then, you can also monitor the health of the BYOI ingest in the Health page (Monitorng > Health).