Commit 8c3decec authored by godog's avatar godog

prometheus: add alerts dashboard

parent 2b4cc804
Pipeline #4533 passed with stage
in 4 minutes and 45 seconds
......@@ -23,3 +23,9 @@
name: docker-prometheus-grafana.service
state: restarted
listen: "restart grafana"
- name: restart karma
systemd:
name: karma.service
state: restarted
listen: "reload karma"
- name: Install karma
apt:
name: karma
state: present
- systemd:
name: karma.service
state: started
enabled: yes
masked: no
- name: "Install karma defaults"
template:
src: "karma.default.j2"
dest: "/etc/default/karma"
notify: "reload karma"
......@@ -41,3 +41,4 @@
notify: "reload prometheus"
- import_tasks: grafana.yml
- import_tasks: karma.yml
ARGS="--listen.port 9193 --listen.prefix /karma/ --silenceform.author.populate_from_header.header X-Authenticated-User --config.file /dev/null --alertmanager.uri http://prometheus:9093 --alertmanager.external_uri https://alertmanager.{{ domain_public[0] }}"
......@@ -94,6 +94,11 @@ prometheus:
port: 9093
scheme: http
enable_sso_proxy: true
- name: alertmanager
path: /karma
port: 9193
scheme: http
enable_sso_proxy: true
- name: prober
port: 9115
scheme: http
......@@ -109,6 +114,9 @@ prometheus:
- job_name: alertmanager
port: 9093
scheme: http
- job_name: karma
port: 9193
scheme: http
- job_name: grafana
port: 2929
scheme: https
......@@ -116,6 +124,7 @@ prometheus:
- prometheus.service
- prometheus-alertmanager.service
- prometheus-blackbox-exporter.service
- karma.service
ports:
- 9094
volumes:
......
......@@ -39,7 +39,7 @@ class TestBuiltinServiceURLs(URLTestBase):
if service_name not in ANSIBLE_VARS['services']:
self.skipTest('service %s not enabled' % service_name)
self._assert_endpoint_ok(public_endpoint_name)
def test_admin_dashboard(self):
self._assert_endpoint_ok_if_enabled('admin-dashboard', 'admin')
......@@ -49,6 +49,9 @@ class TestBuiltinServiceURLs(URLTestBase):
def test_alertmanager(self):
self._assert_endpoint_ok_if_enabled('prometheus', 'alertmanager')
def test_karma(self):
self._assert_endpoint_ok_if_enabled('prometheus', 'alerts')
def test_grafana(self):
self._assert_endpoint_ok_if_enabled('prometheus', 'grafana')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment