Добавление експортера
This commit is contained in:
parent
917a1ffa2b
commit
5d1e1429e8
2 changed files with 19 additions and 2 deletions
|
|
@ -3,6 +3,6 @@ global:
|
||||||
|
|
||||||
scrape_configs:
|
scrape_configs:
|
||||||
- job_name: 'apache'
|
- job_name: 'apache'
|
||||||
metrics_path: '/server-status'
|
metrics_path: '/metrics'
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets: ['10.10.1.2:80']
|
- targets: ['10.10.1.5:9117']
|
||||||
|
|
@ -50,6 +50,21 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- "9090:9090"
|
- "9090:9090"
|
||||||
|
|
||||||
|
exporter:
|
||||||
|
image: lusotycoon/apache-exporter
|
||||||
|
container_name: exporter
|
||||||
|
privileged: true
|
||||||
|
networks:
|
||||||
|
metrics:
|
||||||
|
ipv4_address: 10.10.1.5
|
||||||
|
ports:
|
||||||
|
- mode: ingress
|
||||||
|
target: 9117
|
||||||
|
published: "9117"
|
||||||
|
protocol: tcp
|
||||||
|
restart: unless-stopped
|
||||||
|
entrypoint: /bin/apache_exporter --scrape_uri="http://10.10.1.2/server-status?auto"
|
||||||
|
|
||||||
grafana:
|
grafana:
|
||||||
image: grafana/grafana:11.4.0
|
image: grafana/grafana:11.4.0
|
||||||
networks:
|
networks:
|
||||||
|
|
@ -62,6 +77,8 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- grafana_data:/var/lib/grafana
|
- grafana_data:/var/lib/grafana
|
||||||
- ../../configs/grafana/provisioning:/etc/grafana/provisioning
|
- ../../configs/grafana/provisioning:/etc/grafana/provisioning
|
||||||
|
# - ../grafana/import_dashboard.sh:/docker-entrypoint-init.d/import_dashboard.sh
|
||||||
|
# entrypoint: [ "/bin/sh", "-c", "chmod +x /docker-entrypoint-init.d/import_dashboard.sh && /docker-entrypoint-init.d/import_dashboard.sh" ]
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
db_data:
|
db_data:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue