aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Parczewski <piotr@stackhpc.com>2025-03-26 15:34:21 +0100
committerMichal Nasiadka <mnasiadka@gmail.com>2025-04-22 16:32:38 +0000
commitac79bc9b67823eab6d6e9a027a65261096cfcc19 (patch)
tree148c3c4d14c476ce048b30b457984afbd5d9fc75
parente5e308f034d8d75e8298231c62bcf896273ec8f2 (diff)
downloadkolla-ac79bc9b67823eab6d6e9a027a65261096cfcc19.tar.gz
kolla-ac79bc9b67823eab6d6e9a027a65261096cfcc19.zip
Upgrade Prometheus to v3
Needed-by: https://review.opendev.org/c/openstack/kolla-ansible/+/945611 Change-Id: I4113976db743d3c5c4ff62f2876e224888f05a36
-rw-r--r--docker/prometheus/prometheus-server/Dockerfile.j2 (renamed from docker/prometheus/prometheus-v2-server/Dockerfile.j2)8
-rw-r--r--kolla/common/sources.py8
-rw-r--r--releasenotes/notes/upgrade-prometheus-to-v3-d305280498e0fcaf.yaml11
3 files changed, 19 insertions, 8 deletions
diff --git a/docker/prometheus/prometheus-v2-server/Dockerfile.j2 b/docker/prometheus/prometheus-server/Dockerfile.j2
index e9f47f5c1..bcbc3021b 100644
--- a/docker/prometheus/prometheus-v2-server/Dockerfile.j2
+++ b/docker/prometheus/prometheus-server/Dockerfile.j2
@@ -3,12 +3,12 @@ FROM {{ namespace }}/{{ image_prefix }}prometheus-base:{{ tag }}
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
{% endblock %}
-{% block prometheus_v2_server_header %}{% endblock %}
+{% block prometheus_server_header %}{% endblock %}
{% import "macros.j2" as macros with context %}
-{% block prometheus_v2_server_install %}
-ADD prometheus-v2-server-archive /prometheus-server-source
+{% block prometheus_server_install %}
+ADD prometheus-server-archive /prometheus-server-source
RUN ln -s /prometheus-server-source/* prometheus-server \
&& mkdir -p /opt/prometheus \
@@ -18,7 +18,7 @@ RUN ln -s /prometheus-server-source/* prometheus-server \
{{ macros.kolla_patch_sources() }}
-{% block prometheus_v2_server_footer %}{% endblock %}
+{% block prometheus_server_footer %}{% endblock %}
{% block footer %}{% endblock %}
USER prometheus
diff --git a/kolla/common/sources.py b/kolla/common/sources.py
index 2cbfbf887..1b97167fd 100644
--- a/kolla/common/sources.py
+++ b/kolla/common/sources.py
@@ -394,12 +394,12 @@ SOURCES = {
'releases/download/v${version}/'
'ovn-exporter'
'_${version}_linux_${debian_arch}.tar.gz')},
- 'prometheus-v2-server': {
- 'version': '2.55.1',
+ 'prometheus-server': {
+ 'version': '3.2.1',
'type': 'url',
'sha256': {
- 'amd64': '19700bdd42ec31ee162e4079ebda4cd0a44432df4daa637141bdbea4b1cd8927', # noqa: E501
- 'arm64': 'af43368bc6379c3c8bd5ac0b82208060bba22267bf01ad3ab5df56ad5725bf88'}, # noqa: E501
+ 'amd64': 'a622e3007c9109a7f470e1433cbd29bf392596715cf7eea8b81b37fa9d26b7be', # noqa: E501
+ 'arm64': 'f2dec3178f1181c1b795b275750d056e71ead13f7fbfe08b76834c4ec20b748e'}, # noqa: E501
'location': ('https://github.com/'
'prometheus/prometheus/'
'releases/download/v${version}/'
diff --git a/releasenotes/notes/upgrade-prometheus-to-v3-d305280498e0fcaf.yaml b/releasenotes/notes/upgrade-prometheus-to-v3-d305280498e0fcaf.yaml
new file mode 100644
index 000000000..2550ab095
--- /dev/null
+++ b/releasenotes/notes/upgrade-prometheus-to-v3-d305280498e0fcaf.yaml
@@ -0,0 +1,11 @@
+---
+features:
+ - |
+ Updates Prometheus version to v3.2.1. Also, switches back to
+ the ``prometheus-server`` generic image name by removing the ``v2`` part.
+upgrade:
+ - |
+ Prometheus will be upgraded from v2 to v3 - which introduces minor breaking
+ changes. Make sure there's version 2.5.5 or later running before attempting
+ an upgrade. Read the official migration guide for more details:
+ https://prometheus.io/docs/prometheus/3.0/migration/.