[NTLUG:Discuss] Apache help

Jack Snodgrass idiotboy at cybermail.net
Mon Dec 31 11:17:25 CST 2001


----- Original Message -----
From: "Greg Edwards" <greg at nas-inet.com>
To: "ntlug discuss" <discuss at ntlug.org>
Sent: Saturday, December 29, 2001 11:10 AM
Subject: [NTLUG:Discuss] Apache help


> I've got 2 problems that I can't seem to get resolved with Apache.
>
> The first is trying to get named vhosts to work through a NAT setup.
>
> Internally my virtual hosts resolve correctly.  However, when I setup my
> virtual hosts for outside access all requests resolve to the first
> defined vhost.  I use a single IP to the outside world and I'm routed
> into my webserver through a NAT device.  Has anyone been able to make
> this work?  How?


do you have

NameVirtualHost xxx.xxx.xxx.xxx
where xxx.xxx.xxx.xxx is your 'real' IP Address

and sections like:
<VirtualHost xxx.xxx.xxx.xxx>
ServerAdmin webmaster at somesite.com
lDocumentRoot /some/document/root
ServerName              somesite.com
ErrorLog                logs/somesite.com-error_log
TransferLog             logs/somesite.com-access_log
</VirtualHost>

the namevirtualhost with the IP Address says that users connecting to that
address
may be doing a virtutalhost request and the <virtualhost></virtualhost>
stuff next
maps them to the servername that they are trying to get too.

> The second is trying to use a single directory outside of the web space
> to access include files for .shtml files.
>
> I've tried to declare an alias as "/include/" "/path/include/" and then
> using <!--#include file="/include/somefile.inc"--> it never resolves the
> file.  When I add a symbolic link to the directory that the web page is
> in and use <!--#include file="include/somefile.inc"--> everything works
> as advertised.  Is this an apache bug, or never meant to work this way?
> I am able to prevent access to the include directory but I'd rather not
> have to create a link for every directory that I want to run a .shtml
> file in.
>
> TIA,

#include file can't start with a '/'.
#inclide virutal can, but it's located off of your document root.

jack


> --
> Greg Edwards
> New Age Software, Inc.
> http://www.nas-inet.com
>
> _______________________________________________
> http://www.ntlug.org/mailman/listinfo/discuss
>





More information about the Discuss mailing list