From 35037cf6e4e84164593089e91ec86c30fbe5c03e Mon Sep 17 00:00:00 2001 From: Tobias Manske Date: Sat, 13 Jan 2024 12:27:56 +0100 Subject: [PATCH] Give cadvisor a hostname based label --- ansible/plays/services/metric-export/docker-compose.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/ansible/plays/services/metric-export/docker-compose.yaml b/ansible/plays/services/metric-export/docker-compose.yaml index 61aad6c..3462cb8 100644 --- a/ansible/plays/services/metric-export/docker-compose.yaml +++ b/ansible/plays/services/metric-export/docker-compose.yaml @@ -60,6 +60,7 @@ services: cadvisor: image: gcr.io/cadvisor/cadvisor:latest + container_name: "{{ inventory_hostname | replace('.', '-') }}-cadvisor" privileged: true labels: - "prometheus-scrape.enabled=true"