aboutsummaryrefslogtreecommitdiffstats
path: root/testing/minio/minio.initd
diff options
context:
space:
mode:
Diffstat (limited to 'testing/minio/minio.initd')
-rw-r--r--testing/minio/minio.initd9
1 files changed, 7 insertions, 2 deletions
diff --git a/testing/minio/minio.initd b/testing/minio/minio.initd
index ec6b18825f..44a841a161 100644
--- a/testing/minio/minio.initd
+++ b/testing/minio/minio.initd
@@ -1,4 +1,6 @@
#!/sbin/openrc-run
+supervisor=supervise-daemon
+healthcheck_timer=30
name='Minio Block Storage Server'
command=/usr/bin/minio
@@ -6,9 +8,7 @@ command_args="server \
${address:+--address=$address} \
$MINIO_OPTS \
$MINIO_VOLUMES"
-command_background=true
command_user="minio:minio"
-pidfile="/run/${RC_SVCNAME}.pid"
start_pre() {
# the conf.d file might contain secrets!
@@ -16,3 +16,8 @@ start_pre() {
# make sure the default volume exists
checkpath --directory --mode 0700 --owner minio:minio "/srv/${RC_SVCNAME}"
}
+
+healthcheck() {
+ [ -x /usr/bin/curl ] || return 0
+ /usr/bin/curl -q "$address"/minio/health/ready
+}