Re: [yapcom] Problems Hosting Yapcom on Linux/Apache 2.0.x

[prev] [thread] [next] [lurker] [Date index for 2003/11/24]

From: Shlomi Fish
Subject: Re: [yapcom] Problems Hosting Yapcom on Linux/Apache 2.0.x
Date: 18:21 on 24 Nov 2003
On Sun, 23 Nov 2003, Gabor Szabo wrote:

>
>
> On Sun, 23 Nov 2003, Shlomi Fish wrote:
>
> > <<<
> > # Configuration for Yapcom
> > ScriptAliasMatch ^/yapcom/[a-zA-Z0-9_.-]*$
> > /home/shlomi/progs/perl/yapcom/site/cgi/yapc.pl
> >
> > <Directory /home/shlomi/progs/perl/yapcom/db>
> >     Deny from all
> > </Directory>
> >
> > <Directory /home/shlomi/progs/perl/yapcom/lib>
> >         Deny from all
> > </Directory>
> > >>>
>
>
> I can see only one trange thing here is that in the path to
> yapc.pl you have a 'site'  directory while in the
> orher <Directory> entries you don't.
> This is in itslef not a problem but it might be an indication of
> some  directory structure which is not the same as the script is
> expecting.
>

The problem turned out to be this: the CGI script file refused to serve
files out of the $YAPCOM/files sub-dir. I temporarily resolved it by
adding the following Apache Directive before the ScriptAliasMatch:

<<<
# Configuration for Yapcom
Alias /yapcom/files /home/shlomi/progs/perl/yapcom/site/files/

ScriptAliasMatch ^/yapcom/[a-zA-Z0-9_.-\/]*$
/home/shlomi/progs/perl/yapcom/site/cgi/yapc.pl

<Directory /home/shlomi/progs/perl/yapcom/site/db>
    Deny from all
</Directory>

<Directory /home/shlomi/progs/perl/yapcom/site/lib>
        Deny from all
</Directory>
>>>

Now: we can resolve it permenantly in several ways. One would be to add a
note in the README to add this directive to Apache. The other is to tweak
the CGI script to read and serve files out of this directory if their
prefix is right.

The first method is faster as far as HTTP serving is concerned. The second
one is more user friendly. We can also do the second and recommend to add
the first, so we can make the best of both worlds.

Let me know what path would you like to follow, and I'll send you a patch.

Regards,

	Shlomi Fish



----------------------------------------------------------------------
Shlomi Fish        shlomif@xxxx.xxxxxxxx.xx.xx
Home Page:         http://t2.technion.ac.il/~shlomif/

An apple a day will keep a doctor away. Two apples a day will keep two
doctors away.

	Falk Fish
There's stuff above here

Generated at 20:06 on 24 Nov 2003 by mariachi 0.51