aports/testing/minio/minio.initd
Chloe Kudryavtsev e7b257acce testing/minio: Add openrc, fixup style
Also take ownership.
2019-03-12 02:50:35 +00:00

19 lines
559 B
Plaintext

#!/sbin/openrc-run
name='Minio Block Storage Server'
command=/usr/bin/minio
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!
[ -f "/etc/conf.d/${RC_SVCNAME}" ] && checkpath --file --mode 0600 --owner root:root "/etc/conf.d/${RC_SVCNAME}"
# make sure the default volume exists
checkpath --directory --mode 0700 --owner minio:minio "/srv/${RC_SVCNAME}"
}