From d27e9707a01cba400958d8fc4bfd6aee0e03ccca Mon Sep 17 00:00:00 2001 From: drono Date: Mon, 5 Aug 2024 15:31:35 +0300 Subject: [PATCH] Add Letsencrypt automatic cert generation for monitoring packages --- monitoring/docker-compose.yml | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/monitoring/docker-compose.yml b/monitoring/docker-compose.yml index 2d4de27b..917bafb6 100644 --- a/monitoring/docker-compose.yml +++ b/monitoring/docker-compose.yml @@ -11,7 +11,11 @@ services: - traefik.docker.network=reverse-proxy-traefik_public - traefik.http.routers.grafana.service=grafana - traefik.http.services.grafana.loadbalancer.server.port=3000 - - traefik.http.routers.grafana.rule=Host(${DOMAIN_NAME_HOST_TRAEFIK} && PathPrefix(`/grafana`) + - traefik.http.routers.grafana.rule=Host(${DOMAIN_NAME} && PathPrefix(`/grafana`) + - traefik.http.middlewares.grafana-stripprefix.stripprefix.prefixes=/grafana + - traefik.http.routers.grafana.middlewares=grafana-stripprefix + - traefik.http.routers.openhim-console.tls=true + - traefik.http.services.openhim-console.loadbalancer.server.scheme=http environment: GF_SECURITY_ADMIN_USER: ${GF_SECURITY_ADMIN_USER} GF_SECURITY_ADMIN_PASSWORD: ${GF_SECURITY_ADMIN_PASSWORD} @@ -72,6 +76,7 @@ services: traefik: default: + prometheus: image: prom/prometheus:v2.38.0 user: root @@ -92,6 +97,7 @@ services: public: default: + cadvisor: image: gcr.io/cadvisor/cadvisor:v0.45.0 command: -docker_only @@ -152,7 +158,13 @@ services: MINIO_BROWSER_REDIRECT_URL: ${MINIO_BROWSER_REDIRECT_URL} MINIO_SERVER_URL: http://localhost:9000 healthcheck: - test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"] + test: + [ + "CMD", + "curl", + "-f", + "http://localhost:9000/minio/health/live" + ] interval: 30s timeout: 20s retries: 3 @@ -174,6 +186,7 @@ services: traefik: default: + configs: grafana.ini: file: ./grafana/grafana.ini @@ -258,6 +271,7 @@ volumes: minio-01-data1: minio-01-data2: + networks: keycloak: name: keycloak_public