I am in the middle of moving an application from one server to another in our corporate network. The current production url is http://example1.mycompany.com. We have copied everything onto the new server and can access it using http://example2.mycompany.com. Our team has done our testing to ensure everything is working properly, but we want a fall-back strategy in case the move doesn't work under the typical application load. It can take several days to have our internal dns records changed, so before requesting that example1.mycompany.com be pointed to the new server, I was hoping I could use an .htaccess file with either mod_rewrite or mod_proxy to redirect traffic to the new server without the users knowing that anything has changed so they can copy urls and send them in email as usual.
The other caveat is that in order to authenticate to the application we go through a single signon page and the protocol changes from http to https.
I have tested both suggestions from jpiddle888 but neither of them keeps the browser's address bar looking like it is pointing to the old production server.
Any help would be appreciated.
such-and-such
and this will show a changed URI in the browser. - When you don't want that, you typically configure a "reverse proxy" , where the web server hosting the URI in the original request (example1.com) makes a second request , retrieves the result from a different server (example2.com) and returns the response it receives to the site visitor. This can increase latency and will increase the bandwidth uses for example1.com