]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
cephadm: prometheus: The generatorURL in alerts is only using hostname 46353/head
authorVolker Theile <vtheile@suse.com>
Tue, 10 May 2022 13:25:54 +0000 (15:25 +0200)
committerMichael Fritch <mfritch@suse.com>
Fri, 20 May 2022 03:20:45 +0000 (21:20 -0600)
commit2b4b7c43e95acfaaa838f13a600f08adc1589958
tree3fc10ab41c7c806e30c8f1060820a44ceb312d6c
parent1d4e48ba7c0cdc5eb5c540e3195d4fe23ee5e1f2
cephadm: prometheus: The generatorURL in alerts is only using hostname

Prometheus is currently using only the hostname in the 'generatorURL' of an alert which causes issues when clicking on the URL in the Ceph Dashboard or somewhere else, because in most cases the hostname of the node that is running the Prometheus container is not resolvable.

To fix that the command line argument '--web.external-url' must be appended in the systemd unit file of the Prometheus container, e.g. '--web.external-url http://foo.bar:9095' whereas a FQDN hostname is used.

Fixes: https://tracker.ceph.com/issues/55595
Signed-off-by: Volker Theile <vtheile@suse.com>
(cherry picked from commit 4281dc1bbc466dd061781a984b34bb0eafaf482f)
src/cephadm/cephadm
src/cephadm/tests/test_cephadm.py