From 4e02f3cdb09d90eaf16aa12328e0d2fa193ff12f Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Sun, 5 Jan 2020 13:31:29 -0500 Subject: [PATCH] prometheus: add reload function --- sr.ht/prometheus/APKBUILD | 2 +- sr.ht/prometheus/prometheus.initd | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/sr.ht/prometheus/APKBUILD b/sr.ht/prometheus/APKBUILD index e5594d6..a3de8be 100644 --- a/sr.ht/prometheus/APKBUILD +++ b/sr.ht/prometheus/APKBUILD @@ -72,4 +72,4 @@ package() { sha512sums="b08dfa48bddb6e007cd0fd4553847e824d6adfc047d97151b8dd12dbd1f67cfb9301824b320f1cabe9644159e6968b3fd2ee8104a5d53822a9965423c4bb47b5 prometheus-2.15.1.tar.gz 24b34e586238d5b331639aa5c43b6a927692f251af2cea2787335eab30d2fc7d46975059595db4697ae0dc1d35b5e23cfc4e4b2e424442c209a05283ca22a239 prometheus.confd -bdc179cb3b8b5d3416e74a0b31002bd7b456b204404579dd40c38cade43eb26b106d16ea2597755035035eca567d34bfa44913eaa28870c3f22e1105d47908ab prometheus.initd" +8845d50026c1cea525dae392fa95e06e0b20184325fa0af78e50b5fbc18dabf5526d2ef61798e1e9041840633c6057958e84ef8cce314a7b68ca67fc42bc4fe5 prometheus.initd" diff --git a/sr.ht/prometheus/prometheus.initd b/sr.ht/prometheus/prometheus.initd index 764a8cd..3931e90 100644 --- a/sr.ht/prometheus/prometheus.initd +++ b/sr.ht/prometheus/prometheus.initd @@ -16,3 +16,9 @@ start_pre() { -m 644 -o prometheus:prometheus checkpath -d "$prometheus_storage_path" -m 755 -o prometheus:prometheus } + +reload() { + ebegin "Reloading $RC_SERVNAME" + start-stop-daemon --signal HUP --exec "$command" --pidfile "$pidfile" + eend $? +} -- 2.45.2