diff options
| author | Drew DeVault <sir@cmpwn.com> | 2020-01-08 09:20:02 -0500 |
|---|---|---|
| committer | Leo <thinkabit.ukim@gmail.com> | 2020-01-09 09:17:04 +0100 |
| commit | 4f4fc4a3c8a4a60225f5cbc4eb7fe4c0ac6e6424 (patch) | |
| tree | 2dac6e4cfefec6468c78f97ace2854bab623bbd8 /community/prometheus/prometheus.initd | |
| parent | dc271d205e30a1303b0fac3ff33cdaa68ead4688 (diff) | |
| download | aports-4f4fc4a3c8a4a60225f5cbc4eb7fe4c0ac6e6424.tar.bz2 aports-4f4fc4a3c8a4a60225f5cbc4eb7fe4c0ac6e6424.tar.xz | |
community/prometheus: add reload to init.d
Diffstat (limited to 'community/prometheus/prometheus.initd')
| -rw-r--r-- | community/prometheus/prometheus.initd | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/community/prometheus/prometheus.initd b/community/prometheus/prometheus.initd index 446466225b..3e64da7ad6 100644 --- a/community/prometheus/prometheus.initd +++ b/community/prometheus/prometheus.initd @@ -7,6 +7,7 @@ command_args="--config.file=$prometheus_config_file \ --storage.tsdb.path=$prometheus_storage_path \ --storage.tsdb.retention.time=$prometheus_retention_time" command_user="prometheus:prometheus" +extra_started_commands="reload" start_pre() { [ -n "$output_log" ] && checkpath -f "$output_log" \ @@ -15,3 +16,9 @@ start_pre() { -m 644 -o prometheus:prometheus checkpath -d "$prometheus_storage_path" -m 755 -o prometheus:prometheus } + +reload() { + ebegin "Reloading $RC_SVCNAME" + supervise-daemon $RC_SVCNAME --signal HUP + eend $? +} |
