almost ready
This commit is contained in:
25
monitoring/prometheus/prometheus.service
Normal file
25
monitoring/prometheus/prometheus.service
Normal file
@@ -0,0 +1,25 @@
|
||||
# Prometheus is not in the Grafana apt repo, so install.sh drops the release binary into
|
||||
# /opt/prometheus and installs this unit. Flags: remote-write + OTLP receivers ON (Alloy and
|
||||
# Tempo push to it), 15-day local retention.
|
||||
[Unit]
|
||||
Description=Prometheus
|
||||
Documentation=https://prometheus.io/docs/
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
|
||||
[Service]
|
||||
User=prometheus
|
||||
Group=prometheus
|
||||
Type=simple
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
ExecStart=/opt/prometheus/prometheus \
|
||||
--config.file=/etc/prometheus/prometheus.yml \
|
||||
--storage.tsdb.path=/var/lib/prometheus \
|
||||
--storage.tsdb.retention.time=15d \
|
||||
--web.enable-remote-write-receiver \
|
||||
--web.enable-otlp-receiver \
|
||||
--web.listen-address=0.0.0.0:9090
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
32
monitoring/prometheus/prometheus.yml
Normal file
32
monitoring/prometheus/prometheus.yml
Normal file
@@ -0,0 +1,32 @@
|
||||
# Prometheus for the BlueLaminate observability LXC.
|
||||
#
|
||||
# App + Tempo metrics arrive via REMOTE-WRITE (Alloy and Tempo's metrics_generator push to
|
||||
# /api/v1/write — enabled by the --web.enable-remote-write-receiver flag in prometheus.service),
|
||||
# so they need no scrape config. The scrape jobs below are just the stack's own self-monitoring.
|
||||
|
||||
global:
|
||||
scrape_interval: 30s
|
||||
evaluation_interval: 30s
|
||||
external_labels:
|
||||
monitor: bluelaminate-lxc
|
||||
|
||||
scrape_configs:
|
||||
- job_name: prometheus
|
||||
static_configs:
|
||||
- targets: ["localhost:9090"]
|
||||
|
||||
- job_name: alloy
|
||||
static_configs:
|
||||
- targets: ["localhost:12345"]
|
||||
|
||||
- job_name: loki
|
||||
static_configs:
|
||||
- targets: ["localhost:3100"]
|
||||
|
||||
- job_name: tempo
|
||||
static_configs:
|
||||
- targets: ["localhost:3200"]
|
||||
|
||||
- job_name: grafana
|
||||
static_configs:
|
||||
- targets: ["localhost:3000"]
|
||||
Reference in New Issue
Block a user