You are here
mbottor - Sun, 2013/01/13 - 07:10
I am fairly new to Turnkey and I have one question.
How do I get apache to stop replacing the Internet name www.mysite.com with the IP address.
I thought I could modify the httpd.conf file, but there is nothing in it, so I asume this is done some place else. Or maybe something I can do in webmin?
Be cause of various reasons, DNS is external to this server.
Can someone please point me in the right direction?
Thank you,
Mark
Forum:
httpd.conf is the default Apache conf location
But Debian/Ubuntu (TKL v12 is based on Debian Squeeze) do things a little differently. IMO it is laid out a lot more logically and nicer, but then again I'm used to the Debian/Ubuntu way and am probably biased...
In Debian/Ubuntu it is split up into:
However as you noticed the httpd.conf file still exists and it is read (have a look in apache.conf) so anything in there will still be applied, however other config info elsewhere may override it. So when using Debian I think it's better to do things the Debian way...
Anyway, you should find what you are looking for in the virtual host file. By default that is /etc/apache2/sites-available/default. Personally I would either back that orig file up before you change it, or create a new one (and then disable the default site and enable your new one.
To just back it up:
and then edit it
or to create a whole new site, copy the default to a new site, disable it and enable the new site:
and then edit your new site
IIRC it should be as simple as removing the wildcard (*) and replacing it with your domain name.
Remember that'll you'll need to restart Apache for the config to be applied:
Add new comment