Apache Re-Direction Trick?

Virtualmin
2009-05-19
2013-05-21
  • mark buster
    mark buster
    2009-05-19

    Hey,

    Currently I have a domain up on my virtualmin server. Lets call it website1. This domain is deprecated, so I have another one called website2. I want all users to see the new domain, but still use the data in the old domain.

    Is there a trick so that all users who hit website2 can get forwarded to website1 but the domain in their browser will still show website2?

    I'm hoping theirs some type of hack so I don't have to migrate my data and change a lot of stuff.

    Any help is appreciated. Thanks

    -osmosys

     
    • Joe Cooper
      Joe Cooper
      2009-05-19

      If they run on the same server, you want an Alias server.

      If they run on different servers, you want to use proxy rules.

      Virtualmin can manage either one.  Holler if you run into problems setting either of those up.

       
    • mark buster
      mark buster
      2009-05-19

      Ok this would be an alias situation. I'm going to try it and post my results.

      Thank You

       
    • mark buster
      mark buster
      2009-05-19

      Ok this was incredibly easy. Thanks again for pointing me in the right direction.

      I'm gonna put my steps in here for others.

      1. Log into virtualmin
      2. Click your existing domain name.

      A bunch of options will show up:

      1. Click the button called "Create Alias Server".
      2. Enter your domain in "domain.com"
      3. Click "Create Server".

      Done!

      Make sure your name servers are setup right on both your registrar side and your server side.

      Worked for me! Awesome...