diff options
author | Christian Pointner <equinox@spreadspace.org> | 2021-09-26 04:29:02 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2021-09-26 04:29:02 +0200 |
commit | 223297c29d78e4fe95e2ed2338455708e4e0a9c3 (patch) | |
tree | 02534f529becf59835dd1ed5dee0f2321966a09b /roles/monitoring/prometheus/exporter/nut/tasks | |
parent | switch to pascal for pressure (diff) | |
parent | fix alert wording (diff) |
Merge branch 'topic/prometheus-refactoring'
Diffstat (limited to 'roles/monitoring/prometheus/exporter/nut/tasks')
-rw-r--r-- | roles/monitoring/prometheus/exporter/nut/tasks/main.yml | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/roles/monitoring/prometheus/exporter/nut/tasks/main.yml b/roles/monitoring/prometheus/exporter/nut/tasks/main.yml index 519ac7a0..f602472d 100644 --- a/roles/monitoring/prometheus/exporter/nut/tasks/main.yml +++ b/roles/monitoring/prometheus/exporter/nut/tasks/main.yml @@ -1,4 +1,5 @@ --- + ## TODO: pin version - name: install apt packages apt: name: prom-exporter-nut @@ -20,9 +21,11 @@ - name: register exporter copy: content: | - method: http - http: - port: 9199 - path: /ups_metrics - dest: /etc/prometheus/exporter/enabled/nut.yml - notify: reload prometheus-exporter-exporter + location = /nut { + proxy_pass http://127.0.0.1:9199/metrics; + } + location = /nut/ups { + proxy_pass http://127.0.0.1:9199/ups_metrics; + } + dest: /etc/prometheus/exporter/nut.locations + notify: reload nginx |