From c556601d90310644244df8c4add510839d35782a Mon Sep 17 00:00:00 2001 From: Laur Ivan Date: Thu, 13 Apr 2023 00:57:22 +0200 Subject: [PATCH] chore: Update README. --- README.md | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4e7a8bd..7cbe943 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # laurivan.grafana -This role installs Grafana via Docker. +This role installs Grafana, InfluxDB and Prometheus via Docker. ## Requirements @@ -19,6 +19,7 @@ grafana_volume_base: "/mnt/data/grafana" grafana_setup_path: "{{ grafana_volume_base }}/config" grafana_volume_grafana: "{{ grafana_volume_base }}/grafana" grafana_volume_influxdb: "{{ grafana_volume_base }}/influxdb" +grafana_volume_prometheus: "{{ grafana_volume_base }}/prometheus" ``` You can however define specific volumes for the individual items: @@ -26,6 +27,7 @@ You can however define specific volumes for the individual items: - `grafana_setup_path` - where the Docker compose files are placed - `grafana_volume_grafana` - volume for the grafana docker container - `grafana_volume_influxdb` - volume for InfluxDB +- `grafana_volume_prometheus` - volume for Prometheus.io ### InfluxDB @@ -40,6 +42,25 @@ influxdb: admin_token: change_me ``` +### Prometheus + +We define Prometheus variables: + +```yml +prometheus_port: "9090" + +grafana_prometheus_project: my-project +grafana_prometheus_job_name: prometheus +grafana_prometheus_scrape_interval: '120s' +grafana_prometheus_targets: + - "10.0.0.35:9100" + - "10.0.0.35:8080" +``` + +The targets are locations (ip address + port) where Prometheus polls for new data. This can be [cadvisor](https://github.com/google/cadvisor) or [node exporter](https://github.com/prometheus/node_exporter) for example. + +**Note**: Prometheus should be an internal service (i.e., empty `prometheus_port`). Hence, it doesn't have any security in place. + ### Grafana We also define several variables for grafana