pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pkg/38036: squid startup rc-file broken in pkgsrc-2007Q4
The following reply was made to PR pkg/38036; it has been noted by GNATS.
From: Wolfgang Stukenbrock <Wolfgang.Stukenbrock%nagler-company.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: taca%NetBSD.org@localhost, gnats-admin%NetBSD.org@localhost,
pkgsrc-bugs%NetBSD.org@localhost
Subject: Re: pkg/38036: squid startup rc-file broken in pkgsrc-2007Q4
Date: Thu, 20 Mar 2008 09:26:10 +0100
Hi - once again
I've got a commit message from GNATS some time ago, but now I'v got a
feedback reminder again.
I think the problem is solved.
Can somebody change the state to closed or something simular, please?
Thank you.
W. Stukenbrock
Wolfgang Stukenbrock wrote:
> The following reply was made to PR pkg/38036; it has been noted by GNATS.
>
> From: Wolfgang Stukenbrock
> <Wolfgang.Stukenbrock%nagler-company.com@localhost>
> To: gnats-bugs%NetBSD.org@localhost
> Cc: taca%NetBSD.org@localhost, gnats-admin%NetBSD.org@localhost,
> pkgsrc-bugs%NetBSD.org@localhost
> Subject: Re: pkg/38036: squid startup rc-file broken in pkgsrc-2007Q4
> Date: Mon, 10 Mar 2008 12:20:08 +0100
>
> Hi,
>
> yes this patch look good and solves "our" setup problem.
>
> I've no chance to test the non-Netbsd-startup version at the moment
> (without setting up an additional installation on one of our sun's - and
> I've no time at the moment), but it also looks good to me.
>
> By the way: Why is "createdirs_cmd" a shell function and e.g.
> "reload_cmd" the command itself? Both are only the call of one command.
>
> Best regards,
>
> W. Stukenbrock
>
>
> Takahiro Kambe wrote:
>
> > The following reply was made to PR pkg/38036; it has been noted by GNATS.
> >
> > From: Takahiro Kambe <taca%back-street.net@localhost>
> > To: Wolfgang.Stukenbrock%nagler-company.com@localhost
> > Cc: gnats-bugs%NetBSD.org@localhost
> > Subject: Re: pkg/38036: squid startup rc-file broken in pkgsrc-2007Q4
> > Date: Sun, 09 Mar 2008 13:53:40 +0900 (JST)
> >
> > In message <47BABD11.3030606%nagler-company.com@localhost>
> > on Tue, 19 Feb 2008 12:27:13 +0100,
> > Wolfgang Stukenbrock
> <Wolfgang.Stukenbrock%nagler-company.com@localhost> wrote:
> > > the previous variable start_cmd has command_args included!
> > > If there is a different config file specified than the default, squid
> > > may fail to locate the cache-directory.
> > > Due to the fact that squid seems to ignore other options than "-f" on
> > > the command line if "-z" is given, the command_args should be added in
> > > the create_dirs function too.
> > I really understand the problem.
> >
> > Dose this patch improve your situation?
> >
> > --
> > Takahiro Kambe <taca%back-street.net@localhost>
> >
> > Index: files/squid.sh
> > ===================================================================
> > RCS file: /cvsroot/pkgsrc/www/squid/files/squid.sh,v
> > retrieving revision 1.20
> > diff -u -u -r1.20 squid.sh
> > --- files/squid.sh 31 Jan 2008 20:01:13 -0000 1.20
> > +++ files/squid.sh 9 Mar 2008 04:52:03 -0000
> > @@ -7,20 +7,25 @@
> > # REQUIRE: DAEMON
> > # KEYWORD: shutdown
> >
> > -conf_file="@PKG_SYSCONFDIR@/squid.conf"
> > +if [ -f /etc/rc.subr ]; then
> > + . /etc/rc.subr
> > +fi
> > +
> > +: ${squid_conf:=@PKG_SYSCONFDIR@/squid.conf}
> >
> > name="squid"
> > rcvar=$name
> > command="@PREFIX@/sbin/${name}"
> > pidfile="@VARBASE@/run/${name}.pid"
> > -required_files="${conf_file} @PKG_SYSCONFDIR@/mime.conf"
> > -command_args="-Y -f $conf_file"
> > +required_files="${squid_conf} @PKG_SYSCONFDIR@/mime.conf"
> > +command_args="-Y -f ${squid_conf}"
> >
> > stop_cmd="stop_nicely"
> > kill_command="${command} -k shutdown"
> > reload_cmd="${command} -k reconfigure"
> > rotate_cmd="${command} -k rotate"
> > createdirs_cmd="squid_createdirs"
> > +extra_commands="createdirs reload rotate"
> >
> > #### end of configuration section ####
> >
> > @@ -54,22 +59,20 @@
> > # create the squid cache directories
> > squid_createdirs()
> > {
> > - ${command} -z
> > + ${command} ${squid_flags} ${command_args} -z
> > }
> >
> > -if [ -f /etc/rc.subr -a -d /etc/rc.d -a -f /etc/rc.d/DAEMON ]; then
> > - . /etc/rc.subr
> > - . /etc/rc.conf
> > -
> > - extra_commands="createdirs reload rotate"
> > +if [ -f /etc/rc.subr -a -f /etc/rc.conf -a -f /etc/rc.d/DAEMON ]; then
> > load_rc_config $name
> > run_rc_command "$1"
> > -
> > else # old NetBSD, Solaris, Linux, etc...
> > -
> > + if [ -f /etc/rc.conf ]; then
> > + . /etc/rc.conf
> > + fi
> > case $1 in
> > start)
> > - if [ -x ${command} -a -f ${conf_file} ] ; then
> > + start_cmd="${command} ${squid_flags} ${command_args}"
> > + if [ -x ${command} -a -f ${squid_conf} ] ; then
> > eval ${start_cmd} && @ECHO@ -n " ${name}"
> > fi
> > ;;
> > @@ -94,5 +97,4 @@
> > exit 64
> > ;;
> > esac
> > -
> > fi
> >
> >
>
>
>
Home |
Main Index |
Thread Index |
Old Index