aboutsummaryrefslogtreecommitdiffstats
path: root/www/varnish2
diff options
context:
space:
mode:
authordes <des@FreeBSD.org>2007-06-10 04:35:39 +0800
committerdes <des@FreeBSD.org>2007-06-10 04:35:39 +0800
commit0791ba8f33adf221bfc156e2ec77539d5ad455b8 (patch)
tree4e635736968ed4ffcc8b24fac63752c8357d122b /www/varnish2
parent11f48e18d1863af91d2df796e6abb4e2d0c3889d (diff)
downloadfreebsd-ports-gnome-0791ba8f33adf221bfc156e2ec77539d5ad455b8.tar.gz
freebsd-ports-gnome-0791ba8f33adf221bfc156e2ec77539d5ad455b8.tar.zst
freebsd-ports-gnome-0791ba8f33adf221bfc156e2ec77539d5ad455b8.zip
Fix the rc scripts so it is actually possible to override the defaults.
Diffstat (limited to 'www/varnish2')
-rw-r--r--www/varnish2/Makefile2
-rw-r--r--www/varnish2/files/varnishd.in16
-rw-r--r--www/varnish2/files/varnishlog.in10
3 files changed, 13 insertions, 15 deletions
diff --git a/www/varnish2/Makefile b/www/varnish2/Makefile
index 2e58d01780e2..6e9b39533d96 100644
--- a/www/varnish2/Makefile
+++ b/www/varnish2/Makefile
@@ -7,7 +7,7 @@
PORTNAME= varnish
PORTVERSION= 1.0.4
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= www
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
diff --git a/www/varnish2/files/varnishd.in b/www/varnish2/files/varnishd.in
index 92054025c944..babf2d908701 100644
--- a/www/varnish2/files/varnishd.in
+++ b/www/varnish2/files/varnishd.in
@@ -31,15 +31,13 @@ rcvar=`set_rcvar`
command="%%PREFIX%%/sbin/varnishd"
pidfile="/var/run/${name}.pid"
-# set defaults
-
-varnishd_enable=${varnishd_enable:-"NO"}
-varnishd_listen=${varnishd_listen:-":6081"}
-varnishd_config=${varnishd_config:-"%%PREFIX%%/etc/varnish/default.vcl"}
-varnishd_telnet=${varnishd_telnet:-"localhost:6082"}
-varnishd_storage=${varnishd_storage:-"file,/tmp,50%"}
-varnishd_flags=${varnishd_flags:-"-P ${pidfile} -a ${varnishd_listen} -f ${varnishd_config} -T ${varnishd_telnet} -s ${varnishd_storage}"}
-
+# read configuration and set defaults
load_rc_config ${name}
+: ${varnishd_enable="NO"}
+: ${varnishd_listen=":6081"}
+: ${varnishd_config="%%PREFIX%%/etc/varnish/default.vcl"}
+: ${varnishd_telnet="localhost:6082"}
+: ${varnishd_storage="file,/tmp,50%"}
+: ${varnishd_flags="-P ${pidfile} -a ${varnishd_listen} -f ${varnishd_config} -T ${varnishd_telnet} -s ${varnishd_storage}"}
run_rc_command "$1"
diff --git a/www/varnish2/files/varnishlog.in b/www/varnish2/files/varnishlog.in
index 90dc933c05c1..3c06c610f7bb 100644
--- a/www/varnish2/files/varnishlog.in
+++ b/www/varnish2/files/varnishlog.in
@@ -28,11 +28,11 @@ rcvar=`set_rcvar`
command="%%PREFIX%%/bin/varnishlog"
pidfile="/var/run/${name}.pid"
-# set defaults
-
-varnishlog_enable=${varnishlog_enable:-"NO"}
-varnishlog_file=${varnishlog_file:-"/var/log/varnish.log"}
-varnishlog_flags=${varnishlog_flags:-"-P ${pidfile} -D -a -w ${varnishlog_file}"}
+# read configuration and set defaults
+load_rc_config ${name}
+: ${varnishlog_enable="NO"}
+: ${varnishlog_file="/var/log/varnish.log"}
+: ${varnishlog_flags="-P ${pidfile} -D -a -w ${varnishlog_file}"}
load_rc_config ${name}