WATO: Bakery and Check Parameters in one single file?

Hey guys,

I’m just wondering regarding WATO ruleset definition. Is it fine to distribute the WATO rulesets for check parameters and bakery in one single Python file or should it be separated?

How would a single file (check params & bakery) behave for users with CRE (raw edition) which have not the appropriate python module imports cmk.gui.cee.plugins.wato.agent_bakery.rulespecs.utils available.

What is the best way to go?

Thank you

Best Regards

I do it in two files. With this it is no problem to remove the cee file inside a raw edition or build an own mkp for raw edition.

1 Like

Hi @Notausstieg0309

I keep them separate, however check in the code if the python module is available and do not register the plugin if ti is not.

    from cmk.gui.cee.plugins.wato.agent_bakery.rulespecs.utils import (
except Exception:
    RulespecGroupMonitoringAgentsAgentPlugins = None

if RulespecGroupMonitoringAgentsAgentPlugins is not None:

I use this for example in checkmk_windows_scheduled_task/agent_bakery_win_scheduled_task.py at master · jiuka/checkmk_windows_scheduled_task · GitHub

Regards Marius

1 Like