I have the following virtual host on my development server:
<VirtualHost *:80>
ServerName example.com
DocumentRoot /srv/web/example.com/pub
<Directory /srv/web/example.com/pub>
Order Deny,Allow
Deny from all
Allow from 192.168.0.3
</Directory>
</VirtualHost>
The Allow from 192.168.0.3 part is to only allow requests from my workstation machine.
I want to tweak this to allow anyone to request a certain URL:
http://example.com/public/file.html
How do I change this to allow /public/file.html requests to get through from anyone?
Note: /public/file.html doesn't actually exist as a file on the server. I redirect all incoming requests through a single index file using mod_rewrite.
<Directory>. So if you're rewriting/public/file.htmlto a file outside/srv/web/example.com/pub, it will work. – Lekensteyn Jan 31 '11 at 12:59