Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
aports
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
alpine
aports
Commits
1dccb64e
Commit
1dccb64e
authored
2 years ago
by
raspbeguy
Committed by
alice
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
community/prometheus-node-exporter: upgrade to 1.5.0
parent
6053c504
No related branches found
No related tags found
1 merge request
!41871
community/prometheus-node-exporter: upgrade to 1.5.0
Pipeline
#145399
passed
2 years ago
Stage: verify
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
community/prometheus-node-exporter/APKBUILD
+3
-5
3 additions, 5 deletions
community/prometheus-node-exporter/APKBUILD
community/prometheus-node-exporter/native-endianness.patch
+0
-68
0 additions, 68 deletions
community/prometheus-node-exporter/native-endianness.patch
with
3 additions
and
73 deletions
community/prometheus-node-exporter/APKBUILD
+
3
−
5
View file @
1dccb64e
...
...
@@ -2,8 +2,8 @@
# Maintainer: Tiago Ilieve <tiago.myhro@gmail.com>
pkgname
=
prometheus-node-exporter
_pkgname
=
node_exporter
pkgver
=
1.
4
.0
pkgrel
=
2
pkgver
=
1.
5
.0
pkgrel
=
0
pkgdesc
=
"Prometheus exporter for machine metrics"
url
=
"https://github.com/prometheus/node_exporter"
license
=
"Apache-2.0"
...
...
@@ -15,7 +15,6 @@ source="$_pkgname-$pkgver.tar.gz::https://github.com/prometheus/node_exporter/ar
node-exporter.initd
node-exporter.confd
disable-go-race-detector.patch
native-endianness.patch
"
builddir
=
"
$srcdir
/
$_pkgname
-
$pkgver
"
...
...
@@ -46,9 +45,8 @@ cleanup_srcdir() {
}
sha512sums
=
"
ebb4f9662ba995130b96e108050571119da368a8195e50896a19aab04d7cb40d60f9ae81052a0de08f571886cfb4150bf006a7b67a3d3683f2d04b5f43d61e7a
node_exporter-1.
4
.0.tar.gz
5b6d1da70a3458a1de270bcaf6ab177bd41c8b7031e67a4691b0b79931d15f0e22dbe1533f1ff0474496fcf4433bbd4b3473b8c0063f8891456960d7b6f56e15
node_exporter-1.
5
.0.tar.gz
67b16a002daf45893e7d814e6d921f92dfc26d31ea802a4c511dc3affd8143d3827b7d895bb3efc13337894a893f4feac01d2a0f0e381ef53d00dffe9ff0577a node-exporter.initd
592d3f17a3cf487d97a14c803dded07d2dfb112b159ab1a3575310fc0176fc3255ddad6657f16a8d6d3c161bfb03c203a6271ec6e6395b75716a14b0de8baced node-exporter.confd
36952039e5db39aa06a2ca16fa5d318f22eb967e3e9b1363508b2f3d3d0b14e5df111c77ce951bea2f65dd2be0a0a1582be245acfe4641623381a940204e53d9 disable-go-race-detector.patch
82ae22a0ae8a622d3b62d4900598b17a0c745d902c30e942f12a88448aaa284db2e2f2b282d2f9782ed24848b1ee5aca5bed160b86c2cb5e13d109d62bc08ac0 native-endianness.patch
"
This diff is collapsed.
Click to expand it.
community/prometheus-node-exporter/native-endianness.patch
deleted
100644 → 0
+
0
−
68
View file @
6053c504
Patch-Source: https://github.com/prometheus/node_exporter/pull/2508
From f857150f008d1142618818d3081b693e73f78e55 Mon Sep 17 00:00:00 2001
From: Daniel Swarbrick <daniel.swarbrick@gmail.com>
Date: Sat, 15 Oct 2022 03:03:32 +0200
Subject: [PATCH] Use native endianness when encoding InetDiagMsg
Note however that the InetDiagMsg struct contains a InetDiagSockID
member, which itself contains some members which are explicitly
specified as big-endian in Linux kernel source:
struct inet_diag_sockid {
__be16 idiag_sport;
__be16 idiag_dport;
__be32 idiag_src[4];
__be32 idiag_dst[4];
__u32 idiag_if;
__u32 idiag_cookie[2];
};
node_exporter currently does not use these members for anything, so this
is acceptable (for now).
Signed-off-by: Daniel Swarbrick <daniel.swarbrick@gmail.com>
---
collector/tcpstat_linux_test.go | 3 ++-
go.mod | 2 +-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/collector/tcpstat_linux_test.go b/collector/tcpstat_linux_test.go
index 37dc1eeef..693f04fec 100644
--- a/collector/tcpstat_linux_test.go
+++ b/collector/tcpstat_linux_test.go
@@ -19,13 +19,14 @@
import (
"syscall"
"testing"
+ "github.com/josharian/native"
"github.com/mdlayher/netlink"
)
func Test_parseTCPStats(t *testing.T) {
encode := func(m InetDiagMsg) []byte {
var buf bytes.Buffer
- err := binary.Write(&buf, binary.LittleEndian, m)
+ err := binary.Write(&buf, native.Endian, m)
if err != nil {
panic(err)
}
diff --git a/go.mod b/go.mod
index ce85bb27d..e4947c385 100644
--- a/go.mod
+++ b/go.mod
@@ -12,6 +12,7 @@
require (
github.com/hashicorp/go-envparse v0.0.0-20200406174449-d9cfd743a15e
github.com/hodgesds/perf-utils v0.5.1
github.com/illumos/go-kstat v0.0.0-20210513183136-173c9b0a9973
+ github.com/josharian/native v1.0.0
github.com/jsimonetti/rtnetlink v1.2.2
github.com/lufia/iostat v1.2.1
github.com/mattn/go-xmlrpc v0.0.3
@@ -39,7 +40,6 @@
require (
github.com/go-logfmt/logfmt v0.5.1 // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/go-cmp v0.5.8 // indirect
- github.com/josharian/native v1.0.0 // indirect
github.com/jpillora/backoff v1.0.0 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
github.com/mdlayher/genetlink v1.2.0 // indirect
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment