Files
opennebula-alpine/opennebula-sunstone
santic-zombie 515ed38a2c small fixes
2022-07-03 15:22:46 +03:00

31 lines
694 B
Plaintext

#!/sbin/openrc-run
name=$RC_SVCNAME
description="OpenNebula Web UI Server"
command="/usr/bin/ruby /usr/lib/one/sunstone/sunstone-server.rb"
command_user="oneadmin:cloud"
pidfile="/run/one/${RC_SVCNAME}.pid"
supervisor="supervise-daemon"
depend() {
after syslog networking netmount opennebula
want opennebula-novnc
}
start() {
ebegin "Starting $RC_SVCNAME"
start-stop-daemon --background \
--exec $command \
--make-pidfile --pidfile $pidfile --user $command_user \
--start
eend $?
}
stop() {
ebegin "Stopping $RC_SVCNAME"
start-stop-daemon --stop \
--exec $command \
--pidfile $pidfile --user $command_user
eend $?
}