LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   setting virtualhost without IP (https://www.linuxquestions.org/questions/linux-networking-3/setting-virtualhost-without-ip-37832/)

acid_kewpie 12-10-2002 04:13 AM

setting virtualhost without IP
 
can someone tell me how to set up my apache to redirect to teh right domain without having to specify my IP in httpd.conf? as my IP is technically dynamic i have to change my config each time my ip changes... although this has only ever happened once... a chunk of my conf says:
Code:

# Virtual host Default Virtual Host
<VirtualHost 80.207.153.3>
        ServerName thirtythreeandathird.net
        DocumentRoot /var/www/html
        DirectoryIndex index.php index.html index.htm index.shtml
        LogLevel debug
        HostNameLookups off
</VirtualHost>

# Virtual host mail
<VirtualHost mail.thirtythreeandathird.net>
        DocumentRoot /var/www/html
        ServerName mail.thirtythreeandathird.net
        ServerAlias mail
        LogLevel debug
        RedirectMatch ^.*$ https://www.thirtythreeandathird.net/horde/imp
</VirtualHost>

with the ip in place in the first line it works correctly but if i replace it with the domain name to just thirtythreeandathird.net then it automatically forwards to the second virtualhost here. I'm assuming it uses this one as it's just the next in line. so is it possible to remove my IP altoghether?

peter_robb 12-10-2002 07:43 AM

...

acid_kewpie 12-10-2002 07:45 AM

well, that requires my IP.... i actually have that line already, and was working fine for my old IP, and this one aswell (of course) but i want to be able to remove my ip completey. possible?

acid_kewpie 12-10-2002 07:45 AM

haha..... quite! :D

or spell! ;)


All times are GMT -5. The time now is 08:17 PM.