Skip to content

Commit 1bc3c05

Browse files
committed
Upgrade prometheus to v2.12.0
1 parent 76a2b61 commit 1bc3c05

File tree

5 files changed

+26
-16
lines changed

5 files changed

+26
-16
lines changed

config/blobs.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -114,10 +114,10 @@ prometheus/prometheus-1.8.2.linux-amd64.tar.gz:
114114
size: 17748716
115115
object_id: 54fd8c7b-a676-44cd-64b2-d5788552e607
116116
sha: 33101ac86a6376680c3b44b63db47f1754d77a1a
117-
prometheus/prometheus-2.10.0.linux-amd64.tar.gz:
118-
size: 48497454
119-
object_id: aa8d08ec-1777-4166-4b61-2a6910ee76de
120-
sha: sha256:f4233783826f18606b79e5cef0686e4a9c2030146a3c7ce134f0add09f5adcb7
117+
prometheus/prometheus-2.12.0.linux-amd64.tar.gz:
118+
size: 53127635
119+
object_id: a8c54581-f234-4f4d-5e41-701dcacee34b
120+
sha: sha256:b9f57b6e64fb3048742cfa7dbcc727e1df906d8020ef246a5e81b7959ae97e08
121121
pushgateway/pushgateway-0.9.1.linux-amd64.tar.gz:
122122
size: 8823528
123123
object_id: 0dfd86d9-8128-4466-4f39-419ce4d5058f

jobs/prometheus2/spec

+8
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ consumes:
3131
properties:
3232
prometheus.log_level:
3333
description: "Only log messages with the given severity or above. One of: [debug, info, warn, error]"
34+
prometheus.log_format:
35+
description: "Output format of log messages. One of: [logfmt, json]"
3436
prometheus.scrape_interval:
3537
description: "How frequently to scrape targets by default"
3638
prometheus.scrape_timeout:
@@ -83,6 +85,10 @@ properties:
8385
description: "Maximum duration compacted blocks may span (defaults to 10% of the retention period)"
8486
prometheus.storage.tsdb.no_lockfile:
8587
description: "Do not create lockfile in data directory"
88+
default: false
89+
prometheus.storage.tsdb.wal_compression:
90+
description: "Compress the tsdb WAL"
91+
default: false
8692
prometheus.storage.remote.flush_deadline:
8793
description: "How long to wait flushing sample on shutdown or config reload"
8894
prometheus.storage.remote.read_sample_limit:
@@ -100,8 +106,10 @@ properties:
100106
description: "Regex for CORS origin"
101107
prometheus.web.enable_lifecycle:
102108
description: "Enable shutdown and reload via HTTP request"
109+
default: false
103110
prometheus.web.enable_admin_api:
104111
description: "Enables API endpoints for admin control actions"
112+
default: false
105113
prometheus.web.external_url:
106114
description: "The URL under which Prometheus is externally reachable"
107115
prometheus.web.port:

jobs/prometheus2/templates/bin/prometheus_ctl

+11-9
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ case $1 in
4747
<% if_p('prometheus.log_level') do |log_level| %> \
4848
--log.level="<%= log_level %>" \
4949
<% end %> \
50+
<% if_p('prometheus.log_format') do |log_format| %> \
51+
--log.format="<%= log_format %>" \
52+
<% end %> \
5053
<% if_p('prometheus.query.max_concurrency') do |max_concurrency| %> \
5154
--query.max-concurrency="<%= max_concurrency %>" \
5255
<% end %> \
@@ -81,9 +84,12 @@ case $1 in
8184
<% if_p('prometheus.storage.tsdb.max_block_duration') do |max_block_duration| %> \
8285
--storage.tsdb.max-block-duration="<%= max_block_duration %>" \
8386
<% end %> \
84-
<% if_p('prometheus.storage.tsdb.no_lockfile') do |no_lockfile| %> \
85-
--storage.tsdb.no-lockfile="<%= no_lockfile %>" \
86-
<% end %> \
87+
<% if p('prometheus.storage.tsdb.no_lockfile') %> \
88+
--storage.tsdb.no-lockfile \
89+
<% end %>
90+
<% if p('prometheus.storage.tsdb.wal_compression') %> \
91+
--storage.tsdb.wal-compression \
92+
<% end %>
8793
<% if_p('prometheus.storage.remote.flush_deadline') do |flush_deadline| %> \
8894
--storage.remote.flush-deadline="<%= flush_deadline %>" \
8995
<% end %> \
@@ -102,15 +108,11 @@ case $1 in
102108
<% if_p('prometheus.web.cors_origin') do |cors_origin| %> \
103109
--web.cors.origin="<%= cors_origin %>" \
104110
<% end %> \
105-
<% if_p('prometheus.web.enable_lifecycle') do |enable_lifecycle| %> \
106-
<% if enable_lifecycle %> \
111+
<% if p('prometheus.web.enable_lifecycle') %> \
107112
--web.enable-lifecycle \
108-
<% end %> \
109113
<% end %> \
110-
<% if_p('prometheus.web.enable_admin_api') do |enable_admin_api| %> \
111-
<% if enable_admin_api %> \
114+
<% if p('prometheus.web.enable_admin_api') %> \
112115
--web.enable-admin-api \
113-
<% end %> \
114116
<% end %> \
115117
<% if_p('prometheus.web.external_url') do |external_url| %> \
116118
--web.external-url="<%= external_url %>" \

packages/prometheus2/packaging

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ cp -a ${BOSH_COMPILE_TARGET}/common/* ${BOSH_INSTALL_TARGET}/common
88

99
# Extract prometheus package
1010
mkdir -p ${BOSH_INSTALL_TARGET}/bin
11-
tar xzvf ${BOSH_COMPILE_TARGET}/prometheus/prometheus-2.10.0.linux-amd64.tar.gz
12-
cp -a ${BOSH_COMPILE_TARGET}/prometheus-2.10.0.linux-amd64/* ${BOSH_INSTALL_TARGET}/bin
11+
tar xzvf ${BOSH_COMPILE_TARGET}/prometheus/prometheus-2.12.0.linux-amd64.tar.gz
12+
cp -a ${BOSH_COMPILE_TARGET}/prometheus-2.12.0.linux-amd64/* ${BOSH_INSTALL_TARGET}/bin

packages/prometheus2/spec

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ name: prometheus2
33

44
files:
55
- common/utils.sh
6-
- prometheus/prometheus-2.10.0.linux-amd64.tar.gz
6+
- prometheus/prometheus-2.12.0.linux-amd64.tar.gz

0 commit comments

Comments
 (0)