Accepting request 569480 from security:logging
- Update to 2.1.0 OBS-URL: https://build.opensuse.org/request/show/569480 OBS-URL: https://build.opensuse.org/package/show/server:monitoring/golang-github-prometheus-prometheus?expand=0&rev=3
This commit is contained in:
parent
94d001d618
commit
141b291c5b
@ -1,8 +1,7 @@
|
|||||||
Index: prometheus-2.0.0~rc1/cmd/prometheus/main.go
|
diff -ruN -x '*~' -x '*.o' -x '*.a' -x '*.so' -x '*.so.[0-9]' -x autom4te.cache -x .deps -x .libs ../orig-prometheus-2.1.0/cmd/prometheus/main.go ./cmd/prometheus/main.go
|
||||||
===================================================================
|
--- ../orig-prometheus-2.1.0/cmd/prometheus/main.go 2018-01-19 12:54:28.000000000 +0100
|
||||||
--- prometheus-2.0.0~rc1.orig/cmd/prometheus/main.go
|
+++ ./cmd/prometheus/main.go 2018-01-25 12:07:27.050849457 +0100
|
||||||
+++ prometheus-2.0.0~rc1/cmd/prometheus/main.go
|
@@ -114,7 +114,7 @@
|
||||||
@@ -105,7 +105,7 @@ func main() {
|
|
||||||
a.HelpFlag.Short('h')
|
a.HelpFlag.Short('h')
|
||||||
|
|
||||||
a.Flag("config.file", "Prometheus configuration file path.").
|
a.Flag("config.file", "Prometheus configuration file path.").
|
||||||
@ -11,7 +10,7 @@ Index: prometheus-2.0.0~rc1/cmd/prometheus/main.go
|
|||||||
|
|
||||||
a.Flag("web.listen-address", "Address to listen on for UI, API, and telemetry.").
|
a.Flag("web.listen-address", "Address to listen on for UI, API, and telemetry.").
|
||||||
Default("0.0.0.0:9090").StringVar(&cfg.web.ListenAddress)
|
Default("0.0.0.0:9090").StringVar(&cfg.web.ListenAddress)
|
||||||
@@ -135,13 +135,13 @@ func main() {
|
@@ -144,13 +144,13 @@
|
||||||
Default("false").BoolVar(&cfg.web.EnableAdminAPI)
|
Default("false").BoolVar(&cfg.web.EnableAdminAPI)
|
||||||
|
|
||||||
a.Flag("web.console.templates", "Path to the console template directory, available at /consoles.").
|
a.Flag("web.console.templates", "Path to the console template directory, available at /consoles.").
|
||||||
@ -26,5 +25,5 @@ Index: prometheus-2.0.0~rc1/cmd/prometheus/main.go
|
|||||||
- Default("data/").StringVar(&cfg.localStoragePath)
|
- Default("data/").StringVar(&cfg.localStoragePath)
|
||||||
+ Default("/var/lib/prometheus/metrics/").StringVar(&cfg.localStoragePath)
|
+ Default("/var/lib/prometheus/metrics/").StringVar(&cfg.localStoragePath)
|
||||||
|
|
||||||
a.Flag("storage.tsdb.min-block-duration", "Minimum duration of a data block before being persisted.").
|
a.Flag("storage.tsdb.min-block-duration", "Minimum duration of a data block before being persisted. For use in testing.").
|
||||||
Default("2h").SetValue(&cfg.tsdb.MinBlockDuration)
|
Hidden().Default("2h").SetValue(&cfg.tsdb.MinBlockDuration)
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jan 25 10:11:26 UTC 2018 - kkaempf@suse.com
|
||||||
|
|
||||||
|
- Update to 2.1.0
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Nov 9 07:30:09 UTC 2017 - tserong@suse.com
|
Thu Nov 9 07:30:09 UTC 2017 - tserong@suse.com
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
%{go_nostrip}
|
%{go_nostrip}
|
||||||
|
|
||||||
Name: golang-github-prometheus-prometheus
|
Name: golang-github-prometheus-prometheus
|
||||||
Version: 2.0.0
|
Version: 2.1.0
|
||||||
Release: 0
|
Release: 0
|
||||||
License: Apache-2.0
|
License: Apache-2.0
|
||||||
Summary: The Prometheus monitoring system and time series database
|
Summary: The Prometheus monitoring system and time series database
|
||||||
|
@ -1,25 +1,22 @@
|
|||||||
From 49798c915f249922fb1e1ee87be98b1977ee2579 Mon Sep 17 00:00:00 2001
|
diff -ruN -x '*~' -x '*.o' -x '*.a' -x '*.so' -x '*.so.[0-9]' -x autom4te.cache -x .deps -x .libs ../orig-prometheus-2.1.0/web/web.go ./web/web.go
|
||||||
From: Hylke Visser <htdvisser@gmail.com>
|
--- ../orig-prometheus-2.1.0/web/web.go 2018-01-19 12:54:28.000000000 +0100
|
||||||
Date: Thu, 14 Sep 2017 17:20:22 +0200
|
+++ ./web/web.go 2018-01-25 12:11:59.152359023 +0100
|
||||||
Subject: [PATCH 1/3] Fix REST API gateway loopback address
|
@@ -414,7 +414,21 @@
|
||||||
|
|
||||||
---
|
|
||||||
web/web.go | 9 ++++++++-
|
|
||||||
1 file changed, 8 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/web/web.go b/web/web.go
|
|
||||||
index 13d37dfdb..0d4e93221 100644
|
|
||||||
--- a/web/web.go
|
|
||||||
+++ b/web/web.go
|
|
||||||
@@ -391,7 +391,14 @@ func (h *Handler) Run(ctx context.Context) error {
|
|
||||||
)
|
)
|
||||||
av2.RegisterGRPC(grpcSrv)
|
av2.RegisterGRPC(grpcSrv)
|
||||||
|
|
||||||
- hh, err := av2.HTTPHandler(grpcl.Addr().String())
|
- hh, err := av2.HTTPHandler(h.options.ListenAddress)
|
||||||
+ lAddr := grpcl.Addr().String()
|
+ lAddr := h.options.ListenAddress
|
||||||
+ host, port, _ := net.SplitHostPort(lAddr)
|
+ host, port, err := net.SplitHostPort(lAddr)
|
||||||
|
+ if err != nil {
|
||||||
|
+ return err
|
||||||
|
+ }
|
||||||
+ ip := net.ParseIP(host)
|
+ ip := net.ParseIP(host)
|
||||||
+ if ip.Equal(net.IPv4zero) || ip.Equal(net.IPv6zero) {
|
+ if ip.Equal(net.IPv4zero) || ip.Equal(net.IPv6zero) {
|
||||||
|
+ // The gRPC server is listening on an empty/wildcard address (0.0.0.0 or ::).
|
||||||
|
+ // We should be able to connect to an empty IP just fine, but as there were
|
||||||
|
+ // some issues with this in the past (#3004, #3149), we explicitly tell
|
||||||
|
+ // the REST API gateway to connect to localhost.
|
||||||
+ lAddr = net.JoinHostPort("localhost", port)
|
+ lAddr = net.JoinHostPort("localhost", port)
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
@ -27,54 +24,3 @@ index 13d37dfdb..0d4e93221 100644
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
From 1d3d6614ffe6d04d0b6ae7046bac1709057f4f04 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Hylke Visser <htdvisser@gmail.com>
|
|
||||||
Date: Thu, 14 Sep 2017 21:39:29 +0200
|
|
||||||
Subject: [PATCH 2/3] Add err check for SplitHostPort of Listener address
|
|
||||||
|
|
||||||
---
|
|
||||||
web/web.go | 5 ++++-
|
|
||||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/web/web.go b/web/web.go
|
|
||||||
index 0d4e93221..6e5054906 100644
|
|
||||||
--- a/web/web.go
|
|
||||||
+++ b/web/web.go
|
|
||||||
@@ -392,7 +392,10 @@ func (h *Handler) Run(ctx context.Context) error {
|
|
||||||
av2.RegisterGRPC(grpcSrv)
|
|
||||||
|
|
||||||
lAddr := grpcl.Addr().String()
|
|
||||||
- host, port, _ := net.SplitHostPort(lAddr)
|
|
||||||
+ host, port, err := net.SplitHostPort(lAddr)
|
|
||||||
+ if err != nil {
|
|
||||||
+ return err
|
|
||||||
+ }
|
|
||||||
ip := net.ParseIP(host)
|
|
||||||
if ip.Equal(net.IPv4zero) || ip.Equal(net.IPv6zero) {
|
|
||||||
lAddr = net.JoinHostPort("localhost", port)
|
|
||||||
|
|
||||||
From b2ca81d57eafddc0ff2cbbcf6f00a85d6f81a536 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Hylke Visser <htdvisser@gmail.com>
|
|
||||||
Date: Mon, 18 Sep 2017 14:53:45 +0200
|
|
||||||
Subject: [PATCH 3/3] Add comment to explain the reason for PR #3174
|
|
||||||
|
|
||||||
---
|
|
||||||
web/web.go | 4 ++++
|
|
||||||
1 file changed, 4 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/web/web.go b/web/web.go
|
|
||||||
index 6e5054906..c063963a3 100644
|
|
||||||
--- a/web/web.go
|
|
||||||
+++ b/web/web.go
|
|
||||||
@@ -398,6 +398,10 @@ func (h *Handler) Run(ctx context.Context) error {
|
|
||||||
}
|
|
||||||
ip := net.ParseIP(host)
|
|
||||||
if ip.Equal(net.IPv4zero) || ip.Equal(net.IPv6zero) {
|
|
||||||
+ // The gRPC server is listening on an empty/wildcard address (0.0.0.0 or ::).
|
|
||||||
+ // We should be able to connect to an empty IP just fine, but as there were
|
|
||||||
+ // some issues with this in the past (#3004, #3149), we explicitly tell
|
|
||||||
+ // the REST API gateway to connect to localhost.
|
|
||||||
lAddr = net.JoinHostPort("localhost", port)
|
|
||||||
}
|
|
||||||
|
|
||||||
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:6500fe9e195af5a2d5a35cace1e769a2e7816eb9354ccf2c4271c821d3ad4324
|
|
||||||
size 3489704
|
|
3
prometheus-2.1.0.tar.xz
Normal file
3
prometheus-2.1.0.tar.xz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:7bfdcd36e75448465e1cbc5a8ca46721f3035a896b401130f406d2deb84ed3cf
|
||||||
|
size 3527616
|
Loading…
Reference in New Issue
Block a user