Question
When trying to access my TWIKI intranet site from outside our network, the links or wikiwords won't load. When you click them, they specifiy a local URL instead of the public URL.
eg.
http://servername.domain.local/... instead of the required
http://publicurl.companyname.com/...
The HTTP_Host value is set to servername.domain.local but I can't figure out how to change that or override it.
I am very new to TWIKI so I know very little about scripting and the like.
Does anyone know how I can fix this?
Environment
--
JohnAboud - 16 Jun 2006
Answer
If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.
The contents of the
%HTTP_HOST% variable doesn't come from TWiki, it is configured in the web server's configuration (Configuration item
ServerName). You might also want to check Apache's
UseCanonicalName setting: You need to set this to 'Off' if you want the server to keep the name supplied by the client.
--
HaraldJoerg - 16 Jun 2006
Harald, Thanks for the quick reply. I've double checked the settings for
ServerName and
UseCanonicalName and both are set correctly. However, the TWIKI configuration still displays the server.domain.local value for HTTP_HOST. And the links continue to error.
Any place else I can look?
--
JohnAboud - 16 Jun 2006
The configure has a
{DefaultUrlHost} to specify the host name. However, this is only used if TWiki cannot figure out the host name, such as when running a script from the shell instead of cgi. When you access the view script as a cgi it is picking up the host name dynamically from the current URL, and uses that for the internal links. That is, links are supposed to working properly, even if you can access your data with two different URLs (host names). I am not sure why this does not work in your case.
--
PeterThoeny - 16 Jun 2006
Peter, Thanks for the information. I loaded configure and in the General Path Settings section I have a {wikiHomeUrl} but no {DefaultURLHost} variable listed. The {wikiHomeURL} is set to the correct URL.
Unfortunately I am so new to this I don't know if we are accessing this through a CGI script or not. How would I tell?
--
JohnAboud - 19 Jun 2006
As stated, it should "just work".
You need to work with your local sysadm on the apache installation to get this worked out; it is the apache setup that is the problem here.
--
SteffenPoulsen - 25 Jun 2006
The fix to this problem was with our firewall. We are using MS ISA 2000 for our firewall. When I set up the web publishing rules I failed to notice a check box that will send the original host header instead of substituting the header created by the firewall. I'm still learning.
--
JohnAboud - 12 Jul 2006