From 740451679ffe4b3f6da2b92ead2e4fcf6f18c78b Mon Sep 17 00:00:00 2001 From: Dmitry Paramonov Date: Fri, 27 Sep 2024 15:31:04 +0300 Subject: [PATCH] fix: Update configs --- gateway/traefik.yml.template | 21 +++++++++++++++++++++ prometheus/prometheus_data/prometheus.yml | 2 +- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/gateway/traefik.yml.template b/gateway/traefik.yml.template index 7423e3fde..176d780a1 100644 --- a/gateway/traefik.yml.template +++ b/gateway/traefik.yml.template @@ -37,6 +37,15 @@ http: - agents-api-strip-prefix-api service: service-agents-api priority: 2 + + grafana: + entryPoints: + - web + rule: Path(`/grafana{path:.*}`) + middlewares: + - grafana-strip-prefix-api + service: grafana-service + priority: 3 middlewares: corsHeaders: @@ -62,6 +71,12 @@ http: prefixes: - /api forceSlash: false + + grafana-strip-prefix-api: + stripprefix: + prefixes: + - /grafana + forceSlash: false api-jwt-auth: plugin: @@ -85,6 +100,12 @@ http: passHostHeader: false servers: - url: $AGENTS_API_URL + + grafana-service: + loadBalancer: + passHostHeader: true + servers: + - url: $GRAFANA_URL experimental: localPlugins: diff --git a/prometheus/prometheus_data/prometheus.yml b/prometheus/prometheus_data/prometheus.yml index 9262199d9..cb0439d0e 100644 --- a/prometheus/prometheus_data/prometheus.yml +++ b/prometheus/prometheus_data/prometheus.yml @@ -26,4 +26,4 @@ scrape_configs: scrape_interval: 10s metrics_path: /metrics static_configs: - - targets: ['agents-api:8080'] + - targets: ['agents-api:8000']