Expose Prometheus exporter to the outside world

This commit is contained in:
Eugene Burmakin 2024-11-20 20:42:28 +01:00
parent cf5b414ae4
commit 0a6bb9ab0f
4 changed files with 34 additions and 2 deletions

View file

@ -1 +1 @@
0.16.6
0.16.7

View file

@ -5,6 +5,33 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
# 0.16.7 - 2024-11-20
### Changed
- Prometheus exporter is now bound to 0.0.0.0 instead of localhost
- `PROMETHEUS_EXPORTER_HOST` and `PROMETHEUS_EXPORTER_PORT` env vars were added to the `docker-compose.yml` file to allow you to set the host and port for the Prometheus exporter. They should be added to both `dawarich_app` and `dawarich_sidekiq` services Example:
```diff
dawarich_app:
image: freikin/dawarich:latest
container_name: dawarich_app
environment:
...
PROMETHEUS_EXPORTER_ENABLED: "true"
+ PROMETHEUS_EXPORTER_HOST: 0.0.0.0
+ PROMETHEUS_EXPORTER_PORT: "9394"
dawarich_sidekiq:
image: freikin/dawarich:latest
container_name: dawarich_sidekiq
environment:
...
PROMETHEUS_EXPORTER_ENABLED: "true"
+ PROMETHEUS_EXPORTER_HOST: dawarich_app
+ PROMETHEUS_EXPORTER_PORT: "9394"
```
# 0.16.6 - 2024-11-20
### Added

View file

@ -1,2 +1,2 @@
prometheus_exporter: bundle exec prometheus_exporter -b 0.0.0.0
web: bin/rails server -p 3000 -b 0.0.0.0
prometheus_exporter: bundle exec prometheus_exporter

View file

@ -66,6 +66,8 @@ services:
PHOTON_API_HOST: photon.komoot.io
PHOTON_API_USE_HTTPS: true
PROMETHEUS_EXPORTER_ENABLED: false
PROMETHEUS_EXPORTER_HOST: "0.0.0.0"
PROMETHEUS_EXPORTER_PORT: 9394
logging:
driver: "json-file"
options:
@ -117,6 +119,9 @@ services:
DISTANCE_UNIT: km
PHOTON_API_HOST: photon.komoot.io
PHOTON_API_USE_HTTPS: true
PROMETHEUS_EXPORTER_ENABLED: false
PROMETHEUS_EXPORTER_HOST: dawarich_app
PROMETHEUS_EXPORTER_PORT: 9394
logging:
driver: "json-file"
options: