From 8f995fb4adcf261eb0499e76f7cc659a0297df5e Mon Sep 17 00:00:00 2001 From: kasra Date: Sun, 11 Feb 2024 20:20:53 +0330 Subject: [PATCH] Fix prom config & add another datanode to test compose --- prometheus/prometheus.yml | 12 ++++++------ test.docker-compose.yaml | 21 +++++++++++++++++++++ 2 files changed, 27 insertions(+), 6 deletions(-) diff --git a/prometheus/prometheus.yml b/prometheus/prometheus.yml index 247fedc..7b31675 100644 --- a/prometheus/prometheus.yml +++ b/prometheus/prometheus.yml @@ -17,9 +17,9 @@ scrape_configs: metrics_path: /metrics scheme: http static_configs: - - targets: - - leader_0:9000 - - leader_1:9000 - - datanode_0:9000 - - datanode_1:9000 - - datanode_2:9000 \ No newline at end of file + - targets: ['leader_0:9000'] + - targets: ['leader_1:9000'] + - targets: ['datanode_0:9000'] + - targets: ['datanode_1:9000'] + - targets: ['datanode_2:9000'] + - targets: ['datanode_3:9000'] \ No newline at end of file diff --git a/test.docker-compose.yaml b/test.docker-compose.yaml index 063af98..299ec22 100644 --- a/test.docker-compose.yaml +++ b/test.docker-compose.yaml @@ -108,6 +108,25 @@ services: volumes: - datanode_2_vol:/var/lib/turtlemq/data/ + datanode_3: + image: kysre/turtlemq:datanode-${DATANODE_IMAGE_TAG} + restart: unless-stopped + depends_on: + - leader_0 + - leader_1 + environment: + - HOME_PATH=/var/lib/turtlemq/data/ + - DATANODE_NAME=datanode_3 + - DATANODE_PORT=8000 + - LEADER_HOST=leader_0 + - LEADER_PORT=8888 + - PULL_TIMEOUT=10 + - PENDING_TIMEOUT=15 + - CLEANER_PERIOD=3 + - PARTITIONS_COUNT=100 + volumes: + - datanode_3_vol:/var/lib/turtlemq/data/ + volumes: prom_data: driver: local @@ -119,3 +138,5 @@ volumes: driver: local datanode_2_vol: driver: local + datanode_3_vol: + driver: local