prometheus-snmp-exporter: update

This commit is contained in:
Luke Granger-Brown 2024-01-27 21:00:26 +00:00
parent 1a0f5a5c54
commit 8b4d882663
2 changed files with 19 additions and 1 deletions

View file

@ -0,0 +1,13 @@
diff --git a/generator/Makefile b/generator/Makefile
index 789e96c..2474669 100644
--- a/generator/Makefile
+++ b/generator/Makefile
@@ -20,7 +20,7 @@ DOCKER_IMAGE_NAME ?= snmp-generator
DOCKER_IMAGE_TAG ?= $(subst /,-,$(shell git rev-parse --abbrev-ref HEAD))
DOCKER_REPO ?= prom
-APC_URL := https://download.schneider-electric.com/files?p_enDocType=Firmware&p_File_Name=powernet446.mib&p_Doc_Ref=APC_POWERNETMIB_446_EN
+APC_URL := https://download.schneider-electric.com/files?p_enDocType=Firmware&p_File_Name=powernet449.mib&p_Doc_Ref=APC_POWERNETMIB_449_EN
ARISTA_URL := https://www.arista.com/assets/data/docs/MIBS
CISCO_URL := https://raw.githubusercontent.com/cisco/cisco-mibs/2d465cce2de4e67a3561d8e41e4c99b597558d4b/v2
IANA_CHARSET_URL := https://www.iana.org/assignments/ianacharset-mib/ianacharset-mib

View file

@ -24,7 +24,7 @@ let
version = "lukegb-${prometheus-snmp-exporter.version}";
outputHashMode = "recursive";
outputHash = "sha256:0i2cn5yxb2rnkg91wjmyzd5g2y3cr5yhfkbr9715kw5qk4rf73a0";
outputHash = "sha256:1bsksj21ffzr5b53h2bxk10n8zyasxwxvbfmzrs0x3pbpfmf9bxx";
buildInputs = [
curl
@ -44,6 +44,11 @@ let
cp $src/generator/Makefile $NIX_BUILD_TOP/build/Makefile
'';
patchPhase = ''
sed -i $NIX_BUILD_TOP/build/Makefile -e 's,powernet446,powernet451,g' -e 's,POWERNETMIB_446,POWERNETMIB_451,g'
cat $NIX_BUILD_TOP/build/Makefile
'';
buildPhase = ''
pushd $NIX_BUILD_TOP/build
mkdir mibs