source: hybrid/branches/releng-11/nanobsd/ports/net/transproxy/files/transproxy.in

Last change on this file was 10612, checked in by rick, 13 years ago

Make port building whole bunch more stupid:

1) Bundle ports in the tree itself, instead of global shared banch.
2) Copy the local ports just in the /usr/ports tree to allow playing around

with just the ordenary tools.

  • Property svn:executable set to *
File size: 872 bytes
Line 
1#!/bin/sh
2#
3# $FreeBSD: $
4#
5
6# PROVIDE: transproxy
7# REQUIRE: NETWORKING SERVERS ipfw
8# BEFORE: DAEMON
9# KEYWORD: shutdown
10
11#
12# Add the following line to /etc/rc.conf to enable transproxy:
13#
14# transproxy_enable="YES"
15#
16
17. /etc/rc.subr
18
19name=transproxy
20rcvar=`set_rcvar`
21start_precmd=${name}_precmd
22stop_postcmd=${name}_postcmd
23
24command=%%PREFIX%%/sbin/tproxy
25
26transproxy_port=${transproxy_port:-8081}
27transproxy_log=${transproxy_log:-"/var/log/transproxy.log"}
28transproxy_proxyhost=${transproxy_proxyhost:-"proxy"}
29transproxy_proxyport=${transproxy_proxyport:-3128}
30transproxy_enable=${transproxy_enable:-"NO"}
31transproxy_flags="-s $transproxy_port -l $transproxy_log $transproxy_proxyhost $transproxy_proxyport $transproxy_flags"
32
33transproxy_precmd ()
34{
35
36}
37
38
39transproxy_postcmd ()
40{
41 ipfw delete 10010 10000 10001 >/dev/null
42
43}
44
45
46load_rc_config $name
47run_rc_command "$1"
Note: See TracBrowser for help on using the repository browser.