LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Apache and DNS (https://www.linuxquestions.org/questions/linux-software-2/apache-and-dns-63275/)

Tenchi147 06-02-2003 04:51 PM

Apache and DNS
 
I just bought a domain name from godaddy.com and I am telling it to forward the url that I bought from godaddy to my ip address. When people type in the address (terminalevil.net (my friend thought it up..)) it forwards it to show http://myipaddress. Is there a way I can get apache to change my ip address to say my domain name when it is forwarded to my ip?

trickykid 06-02-2003 04:55 PM

You need to have your registrar (godaddy.com) to point your domain to a valid DNS server so it redirects you and translates the name www.terminalevil.net to IP so it will display as www.terminalevil.net
And also specifying your domain or server name as terminalevil.net in your httpd.conf file on your server.

Tenchi147 06-02-2003 05:08 PM

Godaddy won't let me use the DNS servers because it's set up as a forwarding address. Also, I messed up..the address is http://terminalenemy.net. I was told to set it up as a forwarding address.

Tenchi147 06-02-2003 07:31 PM

Argh this is driving me crazy

mcleodnine 06-02-2003 07:41 PM

What is your "ServerName" in your httpd.conf?

You can set it up to be your fullyqualified domain name and then just use VirtualHost directives in your httpd.conf.

ie:
<VirtualHost *>
ServerName www.terminalenemy.net
DocumentRoot /path/to/htmldocs
</VirtualHost>

You can also place your individual logfiles and other fun stuff within each VirtualHost container.

Tenchi147 06-02-2003 08:03 PM

the ServerName is terminalenemy.net and where would I put the virtual hosts flags? Below where is says NameVirtualHosts * ?

mcleodnine 06-02-2003 08:18 PM

The authoritative DNS server for your domain needs to have either an A record that points to your IP or a CNAME record that points to the origina name record.

If it has a record for www.terminalenemy.net then you can either name your server as that or just use
<VirtualHost *>
ServerName www.terminalenemy.net
DocumentRoot /path/to/your/htmldocs
</VirtualHost>


All times are GMT -5. The time now is 06:13 PM.