Re: Rules file for CERN server question
Ari Luotonen (luotonen@ptsun00.cern.ch)
Fri, 25 Feb 1994 16:07:48 --100
> I am using CERN's WWW server on a VMS 5.5-2 system with MULTINET 3.2C.
> I am trying to serve documents located in different directories (and disks)
> but I have not been able to figure out the exact syntax for my rules file.
> Or, maybe, what I am trying to do cannot be done.
> Here is the rules file I am using. I have no problem http serving docs under
> the /www/* directory tree. Anything outside this tree, is not getting served.
>
> # httpd.conf
> # Rules file for my WWW server
> pass / file:/diska/www/welcome.html
> pass /* file:/diska/www/*
> map /ftp/* file:/diska/www/ftp/*
> map /star/* file:/diskb/star/*
> map /opal/* file:/diskc/opal/*
> pass file:/diska/www/ftp/* <-- this works ok
> pass file:/diskb/star/* <-- does not work
> pass file:/diskc/opal/* <-- does not work
> fail *
> htbin /diska/www/htbin
Rules are translated from top to bottom; first matching Pass, Fail, Exec
or HTBin [HTBin is an obsolite form of Exec, but VMS version doesn't have
Exec yet] will terminate rule translations.
In your case you have
pass /* file:/diska/www/*
which will map _everything_ to diska, and pass it, so further rules
are never reached.
Your config file should read:
# httpd.conf
# Rules file for my WWW server
htbin /diska/www/htbin
pass / file:/diska/www/welcome.html
pass /ftp/* file:/diska/www/ftp/*
pass /star/* file:/diskb/star/*
pass /opal/* file:/diskc/opal/*
pass /* file:/diska/www/*
fail *
It's important to have pass /* ... as the last one.
Cheers,
--
Ari Luotonen |
World-Wide Web Project |
CERN | phone: +41 22 767 8583
CH - 1211 Geneve 23 | email: luotonen@dxcern.cern.ch