We have two webservers, one that hosts our helpdesk web portal (helpdesk.domain.com) and the other host our company's intranet(intranet.domain.com). I am trying to configure Apache webserver hosted on the helpdesk machine(helpdesk.domain.com) to send non-helpdesk.domain.com to the intranet.domain.com. I feel like I am missing something simple because when trying access the helpdesk.DOMAIN.com outside the local network causes a redirect to intranet.DOMAIN.com.
This is my current config file for the helpdesk.DOMAIN.com apache webserver.
<VirtualHost *:80>
ServerName intranet.DOMAIN.com
ProxyPass http://intranet.DOMAIN.com http://192.0.1.22/ nocanon
ProxyPassReverse http://intranet.DOMAIN.com http://192.0.1.22/
ProxyPreserveHost on
ErrorLog ${APACHE_LOG_DIR}/intranet_error.log
CustomLog ${APACHE_LOG_DIR}/intranet_error.log common
</VirtualHost>
<VirtualHost *:80>
ServerName helpdesk.DOMAIN.com
ServerAlias helpdesk.DOMAIN helpdesk.DOMAIN www.helpdesk.DOMAIN.com
ServerAdmin [email protected]
DocumentRoot /var/www/helpdesk.DOMAIN.com
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Helpdesk.domain.com
section if that helps you in the meantime while you wait on a more versed Apache web server person to help you more explicitly. If it was IIS and host headers, I'd probably be able to help but not a lot of repetition with Apache on my side. Might be worth some google or searching around in case it gives you anything further to test out.