From 9cdc80a23870f5b02a44e64347f8011403faab4c Mon Sep 17 00:00:00 2001 From: Raymond Bourges Date: Sat, 14 Mar 2026 06:47:57 +0100 Subject: [PATCH] FEAT : ajout de grafana --- .gitignore | 1 + docker-compose.yml | 27 ++++++++++++++++++++++++++- 2 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c036379 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +tmp/ \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index dea6070..63b2265 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,7 +1,32 @@ services: + timescaledb: image: timescale/timescaledb-ha:pg18 ports: - 5432:5432 environment: - - POSTGRES_PASSWORD=postgres \ No newline at end of file + - POSTGRES_PASSWORD=postgres + volumes: + - ./tmp/data/postgres:/home/postgres/pgdata # TODO : penser à changer sur serveur vs postgres de base ! + + grafana: + image: grafana/grafana:main-ubuntu + ports: + - 3000:3000 + environment: + - GF_SECURITY_ADMIN_USER=admin + - GF_SECURITY_ADMIN_PASSWORD=admin + - GF_USERS_ALLOW_SIGN_UP=false + # - GF_SERVER_DOMAIN=mesures-{{ client.nom }}.arbi.fr + # - GF_SERVER_ROOT_URL=https://mesures-{{ client.nom }}.arbi.fr + - TZ=Europe/Paris + - GF_DATABASE_TYPE=postgres + - GF_DATABASE_HOST=timescaledb:5432 + - GF_DATABASE_NAME=grafana + - GF_DATABASE_USER=postgres + - GF_DATABASE_PASSWORD=postgres + - GF_DATABASE_SSL_MODE=disable + volumes: + - ./tmp/data/grafana:/var/lib/grafana + depends_on: + - timescaledb