aboutsummaryrefslogtreecommitdiff
path: root/utils/prometheus/files/etc/uci-defaults/prometheus-defaults
blob: 9c537d2e829c9d484b08235b8b9513036739bf0c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh

[ -e /etc/config/prometheus ] || touch /etc/config/prometheus

uci -q get prometheus.prometheus || {
	uci -q batch <<EOF
	set prometheus.prometheus=prometheus
	set prometheus.prometheus.config_file='/etc/prometheus.yml'
	set prometheus.prometheus.storage_tsdb_path='/srv/prometheus'
	set prometheus.prometheus.web_listen_address='127.0.0.1:9090'
	commit prometheus
EOF
}