diff --git a/web/plugins/wato/agent_fritzbox_smarthome.py b/web/plugins/wato/agent_fritzbox_smarthome.py deleted file mode 100644 index cc2f86736981940299dbac01368d26e0920ba7d8..0000000000000000000000000000000000000000 --- a/web/plugins/wato/agent_fritzbox_smarthome.py +++ /dev/null @@ -1,91 +0,0 @@ -#!/usr/bin/env python3 -# -*- encoding: utf-8; py-indent-offset: 4 -*- - -# -# modifications by thl-cmk[at]outlook[dot]com -# 2023-12-18: modified to work with cmk 2.2.x -# changed password to use password store -# - -from cmk.gui.i18n import _ -from cmk.gui.plugins.wato.special_agents.common import RulespecGroupDatasourceProgramsHardware -from cmk.gui.plugins.wato.utils import ( - HostRulespec, - rulespec_registry, - IndividualOrStoredPassword, -) -from cmk.gui.valuespec import ( - Dictionary, - FixedValue, - TextAscii, - Integer, - ValueSpec, - DropdownChoice, -) - - -def _valuespec_special_agents_fritzbox_smarthome() -> ValueSpec: - return Dictionary( - title=_("Fritz!Box Smarthome Devices"), - help=_("This rule selects the Fritz!Box agent, which uses HTTP to gather information " - "about configuration and connection status information."), - elements=[ - ('username', - TextAscii( - title=_('Username'), - help=_('Username for the Fritz!Box') - )), - ("password", IndividualOrStoredPassword( - title=_("Password"), - allow_empty=False, - help=_('Password for the Fritz!Box.') - )), - ('port', - Integer( - title=_('Port'), - default_value=443, - )), - ('protocol', - DropdownChoice( - title=_('Protocol'), - choices=[ - ('http', 'HTTP'), - ('https', 'HTTPS'), - ], - default='https', - )), - ('ssl', FixedValue( - value=0, - totext='', - title=_('Ignore SSL errors'), - )), - ('prefix', FixedValue( - value=True, - help='Uses the hostname of the Fritz!Box as prefix for the hostnames generated for piggyback', - totext='', - title=_('Add Prefix'), - )), - ('no_piggyback', FixedValue( - value=True, - help='The agent will not generate piggyback data. ' - 'The Smarthome devices will be attached to the this host.', - totext='', - title=_('Disable piggyback'), - )), - ('testing', FixedValue( - value=True, - help='Development only, will be (most likely) ignored in production :-)', - totext='Add test data to the agent output', - title=_('Add test data'), - )), - ], - required_keys=['username', 'password'] - ) - - -rulespec_registry.register( - HostRulespec( - group=RulespecGroupDatasourceProgramsHardware, - name="special_agents:fritzbox_smarthome", - valuespec=_valuespec_special_agents_fritzbox_smarthome, - ))