[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-modperl
Subject:    Re: alias command in modperl environment
From:       Feng He <fenghe () nsbeta ! info>
Date:       2012-12-20 1:21:45
Message-ID: 50D26829.9070804 () nsbeta ! info
[Download RAW message or body]

Thanks a lot.


于 2012-12-19 23:02, Andy Colson 写道:
> On 12/19/2012 2:40 AM, Feng He wrote:
>> Hello,
>>
>> <VirtualHost *:80>
>>          ServerAdmin xxx@yyy.com
>>          ServerName example.com
>>
>>          PerlModule Apache::DBI
>>          PerlPostConfigRequire /path/to/startup.pl
>>
>>          <Location />
>>              SetHandler modperl
>>              PerlResponseHandler Handler1
>>          </Location>
>>
>>          <Location /ip/>
>>              SetHandler modperl
>>              PerlResponseHandler Handler2
>>          </Location>
>>
>>          Alias /zzz/ "/var/www/zzz/"
>>          <Directory /var/www/zzz/>
>>                  Options FollowSymLinks MultiViews
>>                  AllowOverride None
>>                  Order allow,deny
>>                  allow from all
>>          </Directory>
>>
>>          ErrorLog /var/log/apache2/error.log
>>          LogLevel warn
>>          CustomLog /var/log/apache2/cdn.access.log combined
>>
>> </VirtualHost>
>>
>>
>> I put some static files under /var/www/zzz/.
>> When accessing these static files, I got 403 error.
>> Can't alias command work for this case?
>>
>> Thanks.
>
> Here is an apache config I use that works:
>
> PerlSwitches -I "/pub/www/world"
> PerlModule World
>
> <Location /world>
>          PerlSetupEnv Off
>          SetHandler modperl
>          PerlResponseHandler World
>          Order allow,deny
>          Allow from all
> </Location>
>
> <Location /world/css>
>          SetHandler default-handler
>          Allow from all
> </Location>
>
> <Location /world/js>
>          SetHandler default-handler
>          Allow from all
> </Location>
>
> Alias /world/css /pub/www/world/css
> Alias /world/js /pub/www/world/js
>
>
> -Andy

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic