diff --git a/prometheusd.sh b/prometheusd.sh index ff8e549..6fee544 100755 --- a/prometheusd.sh +++ b/prometheusd.sh @@ -14,8 +14,8 @@ case $1 in start) rm -f "${pid}" - chown prometheus:prometheus /var/lib/prometheus/data - chmod -R u=rwX,g=rX,o= /var/lib/prometheus + chown prometheus:prometheus "${var}" + chmod -R u=rwX,g=rX,o= "${var}" daemonize -p "${pid}" -l "${pid}" -u prometheus -c "${var}" \ /usr/bin/prometheus --config.file=/etc/prometheus/prometheus.yml --storage.tsdb.path="${var}/data"