From: Guillaume Abrioux Date: Tue, 30 Apr 2024 13:27:44 +0000 (+0200) Subject: cephadm: change loki/promtail default image tags X-Git-Tag: v18.2.5~485^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3082ec5126a23753891dffc29c3103dd8f13251a;p=ceph.git cephadm: change loki/promtail default image tags This commit changes the default images for both loki and promtail containers. Also, to allow this update we need to update the configuration of loki in order to add a new storage schema configuration: ``` - from: 2024-05-03 store: tsdb object_store: filesystem schema: v13 index: prefix: index_ period: 24h ``` This is because 3.0.0 uses new structured metadata. See [1][2]. [1] https://grafana.com/docs/loki/latest/operations/storage/schema/ [2] https://grafana.com/docs/loki/latest/get-started/labels/structured-metadata/#when-to-use-structured-metadata Fixes: https://tracker.ceph.com/issues/65784 Signed-off-by: Guillaume Abrioux (cherry picked from commit 00f5257a5b07694dd8d06ecc8cd4c060025f81bf) --- diff --git a/src/cephadm/cephadm.py b/src/cephadm/cephadm.py index c718106400f..fcbde719b9e 100755 --- a/src/cephadm/cephadm.py +++ b/src/cephadm/cephadm.py @@ -49,8 +49,8 @@ DEFAULT_IMAGE = 'quay.io/ceph/ceph:v18' DEFAULT_IMAGE_IS_MAIN = False DEFAULT_IMAGE_RELEASE = 'reef' DEFAULT_PROMETHEUS_IMAGE = 'quay.io/prometheus/prometheus:v2.43.0' -DEFAULT_LOKI_IMAGE = 'docker.io/grafana/loki:2.4.0' -DEFAULT_PROMTAIL_IMAGE = 'docker.io/grafana/promtail:2.4.0' +DEFAULT_LOKI_IMAGE = 'docker.io/grafana/loki:3.0.0' +DEFAULT_PROMTAIL_IMAGE = 'docker.io/grafana/promtail:3.0.0' DEFAULT_NODE_EXPORTER_IMAGE = 'quay.io/prometheus/node-exporter:v1.5.0' DEFAULT_ALERT_MANAGER_IMAGE = 'quay.io/prometheus/alertmanager:v0.25.0' DEFAULT_GRAFANA_IMAGE = 'quay.io/ceph/ceph-grafana:9.4.7' diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py index 7945f52940b..4772574169c 100644 --- a/src/pybind/mgr/cephadm/module.py +++ b/src/pybind/mgr/cephadm/module.py @@ -120,8 +120,8 @@ DEFAULT_IMAGE = 'quay.io/ceph/ceph' # DO NOT ADD TAG TO THIS DEFAULT_PROMETHEUS_IMAGE = 'quay.io/prometheus/prometheus:v2.43.0' DEFAULT_NODE_EXPORTER_IMAGE = 'quay.io/prometheus/node-exporter:v1.5.0' DEFAULT_NVMEOF_IMAGE = 'quay.io/ceph/nvmeof:1.0.0' -DEFAULT_LOKI_IMAGE = 'docker.io/grafana/loki:2.4.0' -DEFAULT_PROMTAIL_IMAGE = 'docker.io/grafana/promtail:2.4.0' +DEFAULT_LOKI_IMAGE = 'docker.io/grafana/loki:3.0.0' +DEFAULT_PROMTAIL_IMAGE = 'docker.io/grafana/promtail:3.0.0' DEFAULT_ALERT_MANAGER_IMAGE = 'quay.io/prometheus/alertmanager:v0.25.0' DEFAULT_GRAFANA_IMAGE = 'quay.io/ceph/ceph-grafana:9.4.7' DEFAULT_HAPROXY_IMAGE = 'quay.io/ceph/haproxy:2.3' diff --git a/src/pybind/mgr/cephadm/templates/services/loki.yml.j2 b/src/pybind/mgr/cephadm/templates/services/loki.yml.j2 index 27143723113..70ad46df66e 100644 --- a/src/pybind/mgr/cephadm/templates/services/loki.yml.j2 +++ b/src/pybind/mgr/cephadm/templates/services/loki.yml.j2 @@ -26,3 +26,10 @@ schema_config: index: prefix: index_ period: 24h + - from: 2024-05-03 + store: tsdb + object_store: filesystem + schema: v13 + index: + prefix: index_ + period: 24h diff --git a/src/pybind/mgr/cephadm/tests/test_services.py b/src/pybind/mgr/cephadm/tests/test_services.py index b6a407e091e..e0cbdea1b2c 100644 --- a/src/pybind/mgr/cephadm/tests/test_services.py +++ b/src/pybind/mgr/cephadm/tests/test_services.py @@ -989,6 +989,13 @@ class TestMonitoring: store: boltdb-shipper object_store: filesystem schema: v11 + index: + prefix: index_ + period: 24h + - from: 2024-05-03 + store: tsdb + object_store: filesystem + schema: v13 index: prefix: index_ period: 24h""").lstrip()