| Server IP : 82.208.35.60 / Your IP : 216.73.216.89 Web Server : Apache/2.4.55 (FreeBSD) OpenSSL/1.1.1q-freebsd PHP/7.3.31 System : FreeBSD server7.d2m.cz 12.4-RELEASE-p9 FreeBSD 12.4-RELEASE-p9 GENERIC amd64 User : studiokobylisy_cz ( 1008) PHP Version : 7.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /usr/ports/www/h2o/files/ |
Upload File : |
#!/bin/sh
# PROVIDE: h2o
# REQUIRE: LOGIN DAEMON NETWORKING
# KEYWORD: shutdown
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# h2o_enable (bool): Set to NO by default.
# Set it to YES to enable h2o.
#
# h2o_config (string): Optional full path for h2o config file
# h2o_perl (string): Optional full path to perl executable
. /etc/rc.subr
name=h2o
rcvar=h2o_enable
desc="An HTTP/2 high-performance webserver"
load_rc_config $name
extra_commands="configtest reload"
configtest_cmd="h2o_configtest"
# defaults
: ${h2o_enable:=NO}
: ${h2o_config:=%%PREFIX%%/etc/${name}/${name}.conf}
: ${h2o_perl:=%%LOCALBASE%%/bin/perl}
# daemon
pidfile=`grep pid-file ${h2o_config} | awk '{print $2}'`
h2o_env="H2O_PERL=${h2o_perl}"
command="%%PREFIX%%/bin/${name}"
command_args="-m daemon -c ${h2o_config}"
procname="%%LOCALBASE%%/bin/perl"
h2o_configtest() {
"${command}" -c "${h2o_config}" -t
}
run_rc_command "$1"