prometheus-node-exporter-lua: hostad ubus stats

There is already the hostapd_stations exporter, which uses
hostapd-utils (more precisely hostapd-cli) to get client statistics.
However, the ubus interface is permanently integrated under hostapd
in OpenWrt. So this exporter needs one dependency less.

For now it exports mainly the rrm statistics. Many people are
interested in what your device supports. The exporter provides
information about the radio-resource-managment extensions.

Signed-off-by: Nick Hainke <vincent@systemli.org>
This commit is contained in:
Nick Hainke
2020-10-08 14:40:00 +02:00
parent 871975ddff
commit d34d788735
2 changed files with 81 additions and 1 deletions

View File

@@ -4,7 +4,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=prometheus-node-exporter-lua
PKG_VERSION:=2020.10.01
PKG_VERSION:=2020.10.10
PKG_RELEASE:=1
PKG_MAINTAINER:=Etienne CHAMPETIER <champetier.etienne@gmail.com>
@@ -100,6 +100,17 @@ define Package/prometheus-node-exporter-lua-hostapd_stations/install
$(INSTALL_BIN) ./files/usr/lib/lua/prometheus-collectors/hostapd_stations.lua $(1)/usr/lib/lua/prometheus-collectors/
endef
define Package/prometheus-node-exporter-lua-hostapd_ubus_stations
$(call Package/prometheus-node-exporter-lua/Default)
TITLE+= (hostapd_ubus_stations collector)
DEPENDS:=prometheus-node-exporter-lua +luabitop +libubus-lua
endef
define Package/prometheus-node-exporter-lua-hostapd_ubus_stations/install
$(INSTALL_DIR) $(1)/usr/lib/lua/prometheus-collectors
$(INSTALL_BIN) ./files/usr/lib/lua/prometheus-collectors/hostapd_ubus_stations.lua $(1)/usr/lib/lua/prometheus-collectors/
endef
define Package/prometheus-node-exporter-lua-ltq-dsl
$(call Package/prometheus-node-exporter-lua/Default)
TITLE+= (lantiq dsl collector)
@@ -193,6 +204,7 @@ $(eval $(call BuildPackage,prometheus-node-exporter-lua-bmx6))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-bmx7))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-dawn))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-hostapd_stations))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-hostapd_ubus_stations))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-ltq-dsl))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-nat_traffic))
$(eval $(call BuildPackage,prometheus-node-exporter-lua-netstat))