From 7afb2e8e89cdeba8a7e2c64e248b4ab06eab7951 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20M=C3=BCnch?= Date: Sun, 23 Jun 2024 18:54:18 +0200 Subject: [PATCH] Add `system health settings` path Add changelog fragment Change changelog fragment to lower-case --- .../294-add-system-health-settings-path.yml | 2 + plugins/module_utils/_api_data.py | 38 +++++++++++++++++++ plugins/modules/api_info.py | 1 + plugins/modules/api_modify.py | 1 + 4 files changed, 42 insertions(+) create mode 100644 changelogs/fragments/294-add-system-health-settings-path.yml diff --git a/changelogs/fragments/294-add-system-health-settings-path.yml b/changelogs/fragments/294-add-system-health-settings-path.yml new file mode 100644 index 00000000..13d38b4f --- /dev/null +++ b/changelogs/fragments/294-add-system-health-settings-path.yml @@ -0,0 +1,2 @@ +minor_changes: + - api_info, api_modify - add ``system health settings`` path (https://github.com/ansible-collections/community.routeros/pull/294). diff --git a/plugins/module_utils/_api_data.py b/plugins/module_utils/_api_data.py index 0883a2f5..e13b7e9c 100644 --- a/plugins/module_utils/_api_data.py +++ b/plugins/module_utils/_api_data.py @@ -4001,6 +4001,44 @@ def join_path(path): }, ), ), + ('system', 'health', 'settings'): APIData( + versioned=[ + ('7.14', '<', VersionedAPIData( + single_value=True, + fully_understood=True, + fields={ + 'cpu-overtemp-check': KeyInfo(), + 'cpu-overtemp-startup-delay': KeyInfo(), + 'cpu-overtemp-threshold': KeyInfo(), + 'fan-control-interval': KeyInfo(can_disable=True, default='30s'), + 'fan-full-speed-temp': KeyInfo(default=65), + 'fan-min-speed-percent': KeyInfo(default=0), + 'fan-mode': KeyInfo(), + 'fan-on-threshold': KeyInfo(), + 'fan-switch': KeyInfo(), + 'fan-target-temp': KeyInfo(default=58), + 'use-fan': KeyInfo(), + }, + )), + ('7.14', '>=', VersionedAPIData( + single_value=True, + fully_understood=True, + fields={ + 'cpu-overtemp-check': KeyInfo(), + 'cpu-overtemp-startup-delay': KeyInfo(), + 'cpu-overtemp-threshold': KeyInfo(), + 'fan-control-interval': KeyInfo(default=30), + 'fan-full-speed-temp': KeyInfo(default=65), + 'fan-min-speed-percent': KeyInfo(default=12), + 'fan-mode': KeyInfo(), + 'fan-on-threshold': KeyInfo(), + 'fan-switch': KeyInfo(), + 'fan-target-temp': KeyInfo(default=58), + 'use-fan': KeyInfo(), + }, + )), + ], + ), ('system', 'identity'): APIData( unversioned=VersionedAPIData( single_value=True, diff --git a/plugins/modules/api_info.py b/plugins/modules/api_info.py index 1d5dea56..f152a81b 100644 --- a/plugins/modules/api_info.py +++ b/plugins/modules/api_info.py @@ -218,6 +218,7 @@ - snmp community - system clock - system clock manual + - system health settings - system identity - system leds settings - system logging diff --git a/plugins/modules/api_modify.py b/plugins/modules/api_modify.py index 73a08eff..46ee18b6 100644 --- a/plugins/modules/api_modify.py +++ b/plugins/modules/api_modify.py @@ -227,6 +227,7 @@ - snmp community - system clock - system clock manual + - system health settings - system identity - system leds settings - system logging