From 07b4d4a25d82cd1582e4f8d8b2e374f384830584 Mon Sep 17 00:00:00 2001 From: Sven Panne Date: Thu, 16 Jan 2025 12:22:13 +0100 Subject: [PATCH] Simplified RRD helper commandline * "Requiring an option" is an oxymoron. :-D * Passing an RRD spec for manual RRD creation was removed in 1.6. Change-Id: I7237f3484dd94ee3b8de1ff0ae035ea73e3f0a6f --- cmk/base/modes/__init__.py | 5 ----- cmk/base/modes/check_mk.py | 7 +++++-- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/cmk/base/modes/__init__.py b/cmk/base/modes/__init__.py index 17d5b01ca47..136e9a04f27 100644 --- a/cmk/base/modes/__init__.py +++ b/cmk/base/modes/__init__.py @@ -469,11 +469,6 @@ def get_sub_options(self, all_opts: Options) -> dict[OptionName, Argument | int return options -keepalive_option = Option( - long_option="keepalive", - short_help="Execute in keepalive mode (CEE only)", -) - # # Initialize the modes object and load all available modes # diff --git a/cmk/base/modes/check_mk.py b/cmk/base/modes/check_mk.py index 6274a6a3554..9b4d7d6c9a5 100644 --- a/cmk/base/modes/check_mk.py +++ b/cmk/base/modes/check_mk.py @@ -131,7 +131,7 @@ ) from cmk.base.core_factory import create_core, get_licensing_handler_type from cmk.base.errorhandling import CheckResultErrorHandler, create_section_crash_dump -from cmk.base.modes import keepalive_option, Mode, modes, Option +from cmk.base.modes import Mode, modes, Option from cmk.base.sources import make_parser, SNMPFetcherConfig from cmk.base.utils import register_sigint_handler @@ -1800,7 +1800,10 @@ def ensure_nagios(msg: str) -> None: long_option="log-to-stdout", short_help="Also write log messages to console", ), - keepalive_option, + Option( + long_option="keepalive", + short_help="Execute in keepalive mode (CEE only)", + ), ], ) )