From eb46f5905ffbe4041814f240e81cafb0db3e618b Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 6 Jun 2024 08:16:48 +0000 Subject: [PATCH 1/2] fix(deps): update module github.com/shirou/gopsutil/v3 to v4 --- go.mod | 5 ++++- go.sum | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 696f6930..97ba580c 100644 --- a/go.mod +++ b/go.mod @@ -29,7 +29,10 @@ require ( sigs.k8s.io/controller-tools v0.15.0 ) -require github.com/shirou/gopsutil/v3 v3.24.5 +require ( + github.com/shirou/gopsutil/v3 v3.24.5 + github.com/shirou/gopsutil/v4 v4.24.5 +) require ( cel.dev/expr v0.15.0 // indirect diff --git a/go.sum b/go.sum index 56977307..0be5776b 100644 --- a/go.sum +++ b/go.sum @@ -134,6 +134,7 @@ github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncj github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/shirou/gopsutil/v3 v3.24.5 h1:i0t8kL+kQTvpAYToeuiVk3TgDeKOFioZO3Ztz/iZ9pI= github.com/shirou/gopsutil/v3 v3.24.5/go.mod h1:bsoOS1aStSs9ErQ1WWfxllSeS1K5D+U30r2NfcubMVk= +github.com/shirou/gopsutil/v4 v4.24.5/go.mod h1:aoebb2vxetJ/yIDZISmduFvVNPHqXQ9SEJwRXxkf0RA= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/shoenig/test v0.6.4 h1:kVTaSd7WLz5WZ2IaoM0RSzRsUD+m8wRR+5qvntpn4LU= From b0011949aa5d03ed60317dd72d3e0346d14258e5 Mon Sep 17 00:00:00 2001 From: Kai Kummerer Date: Fri, 7 Jun 2024 15:25:24 +0200 Subject: [PATCH 2/2] update gopsutil to v4 --- go.mod | 5 +---- go.sum | 3 +-- internal/helper/yawollet.go | 2 +- internal/hostmetrics/hostmetrics.go | 8 ++++---- 4 files changed, 7 insertions(+), 11 deletions(-) diff --git a/go.mod b/go.mod index 97ba580c..f64cbdba 100644 --- a/go.mod +++ b/go.mod @@ -29,10 +29,7 @@ require ( sigs.k8s.io/controller-tools v0.15.0 ) -require ( - github.com/shirou/gopsutil/v3 v3.24.5 - github.com/shirou/gopsutil/v4 v4.24.5 -) +require github.com/shirou/gopsutil/v4 v4.24.5 require ( cel.dev/expr v0.15.0 // indirect diff --git a/go.sum b/go.sum index 0be5776b..9505a96c 100644 --- a/go.sum +++ b/go.sum @@ -132,8 +132,7 @@ github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3c github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/shirou/gopsutil/v3 v3.24.5 h1:i0t8kL+kQTvpAYToeuiVk3TgDeKOFioZO3Ztz/iZ9pI= -github.com/shirou/gopsutil/v3 v3.24.5/go.mod h1:bsoOS1aStSs9ErQ1WWfxllSeS1K5D+U30r2NfcubMVk= +github.com/shirou/gopsutil/v4 v4.24.5 h1:gGsArG5K6vmsh5hcFOHaPm87UD003CaDMkAOweSQjhM= github.com/shirou/gopsutil/v4 v4.24.5/go.mod h1:aoebb2vxetJ/yIDZISmduFvVNPHqXQ9SEJwRXxkf0RA= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= diff --git a/internal/helper/yawollet.go b/internal/helper/yawollet.go index 864f5a41..79032638 100644 --- a/internal/helper/yawollet.go +++ b/internal/helper/yawollet.go @@ -20,7 +20,7 @@ import ( v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/tools/record" - "github.com/shirou/gopsutil/v3/process" + "github.com/shirou/gopsutil/v4/process" yawolv1beta1 "github.com/stackitcloud/yawol/api/v1beta1" "github.com/stackitcloud/yawol/internal/envoystatus" diff --git a/internal/hostmetrics/hostmetrics.go b/internal/hostmetrics/hostmetrics.go index 983c7937..773ff810 100644 --- a/internal/hostmetrics/hostmetrics.go +++ b/internal/hostmetrics/hostmetrics.go @@ -6,10 +6,10 @@ import ( "runtime" "strconv" - "github.com/shirou/gopsutil/v3/cpu" - "github.com/shirou/gopsutil/v3/host" - "github.com/shirou/gopsutil/v3/load" - "github.com/shirou/gopsutil/v3/mem" + "github.com/shirou/gopsutil/v4/cpu" + "github.com/shirou/gopsutil/v4/host" + "github.com/shirou/gopsutil/v4/load" + "github.com/shirou/gopsutil/v4/mem" ) func formatFloat(f float64) string {