minor changes on volumes/networks

This commit is contained in:
tom.chivert
2025-12-01 14:53:07 +01:00
parent 6778671d89
commit 76ea4ddd58
2 changed files with 9 additions and 9 deletions

View File

@@ -1,5 +1,3 @@
version: '3.7'
networks:
{{ prometheus_docker_network }}:
external: true

View File

@@ -1,7 +1,6 @@
version: "3"
networks:
grafana:
{{ prometheus_docker_network }}:
name: {{ prometheus_docker_network }}
{% if grafana_traefik_enable is defined %}
traefik:
external: true
@@ -10,10 +9,13 @@ networks:
volumes:
{% if prometheus_use_victoriametrics == false %}
prometheus-data:
name: prometheus-data
{% else %}
victoria-metrics-data:
name: victoria-metrics-data
{% endif %}
grafana-data:
name: grafana-data
services:
grafana:
@@ -55,7 +57,7 @@ services:
GF_SMTP_ENABLED: "false"
{% endif %}
networks:
- grafana
- {{ prometheus_docker_network }}
{% if grafana_traefik_enable is defined %}
- traefik
{% endif %}
@@ -91,7 +93,7 @@ services:
- '--storage.tsdb.retention.time={{ prometheus_retention_time }}'
- '--web.enable-lifecycle'
networks:
- grafana
- {{ prometheus_docker_network }}
{% if prometheus_traefik_enable is defined %}
- traefik
{% endif %}
@@ -148,7 +150,7 @@ services:
- "{{ prometheus_port | default(8428) }}:8428"
{% endif %}
networks:
- grafana
- {{ prometheus_docker_network }}
vmagent:
image: victoriametrics/vmagent
@@ -163,7 +165,7 @@ services:
labels:
com.centurylinklabs.watchtower.enable: {{ prometheus_watchtower_enable | default('true') }}
networks:
- grafana
- {{ prometheus_docker_network }}
{% if prometheus_nodes_ip is defined %}
extra_hosts:
{% for key, value in prometheus_nodes_ip.items() %}