health: control LEDs via sysrepo and ietf-alarms

This patch introduces a sysrepo subscription that listens for changes
in ietf-alarms' operational datastore and whenever the alarm count
changes it triggers a callback. We write this code with the intention
to use it for controlling LED colour but it is generic so one can plug
another stuff that somehow reacts to the number of alarms.

For now we only react on changes in the alarms list. We consider only
uncleared alarms. We set the output state to OK or ERROR based on the
count of alarms (if 0 alarms then OK else ERROR) and we let the output
signal to handle the state change somehow (e.g. light up different LED).

Change-Id: I5958975f246f96762389aae27b1974d5eea4093d
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b77162f..0cef9d5 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -118,6 +118,8 @@
     src/health/inputs/DbusSystemdInput.cpp
     src/health/manager/AbstractManager.cpp
     src/health/manager/StateManager.cpp
+    src/health/outputs/AlarmsOutputs.cpp
+    src/health/outputs/AlarmsOutputs.h
     src/health/outputs/LedSysfsDriver.cpp
     src/health/outputs/callables.cpp
     src/health/State.cpp
@@ -508,6 +510,7 @@
         YANG ${CMAKE_CURRENT_SOURCE_DIR}/tests/yang/sysrepo-ietf-alarms@2022-02-17.yang
     )
 	velia_test(NAME health_systemd-units LIBRARIES velia-health DbusTesting FIXTURE fixture_sysrepo-alarms)
+	velia_test(NAME sysrepo_health-led-alarms LIBRARIES velia-health DbusTesting FIXTURE fixture_sysrepo-alarms)
 endif()
 
 if(WITH_DOCS)