This is the first time that I am going to be running two websites off the same Matrix install, both of which have their own URLs. Both URLs are pointed to the ip of my Matrix server, and both URLs are configured correctly in system config, the sites load fine.
My issue is, what should I be adding to my apache Virtual Host file? Currently, the ServerName and ServerAlias reference the first site I built. But, I really need to add some Rewrite rules for my second site as well, but putting those into the first sites block does not do well.
Should I create a separate virtual host block for each URL, and for each block add all the normal Matrix Alias' and directory info?
Just want to make sure I get this right…
Hi,
[quote]
This is the first time that I am going to be running two websites off the same Matrix install, both of which have their own URLs. Both URLs are pointed to the ip of my Matrix server, and both URLs are configured correctly in system config, the sites load fine.
My issue is, what should I be adding to my apache Virtual Host file? Currently, the ServerName and ServerAlias reference the first site I built. But, I really need to add some Rewrite rules for my second site as well, but putting those into the first sites block does not do well.
Should I create a separate virtual host block for each URL, and for each block add all the normal Matrix Alias' and directory info?
Just want to make sure I get this right…
[/quote]
You can just add the extra domain(s) to the ServerAlias, restart apache and you'll be off and running.
ie -
ServerAlias domain1.com www.domain2.com domain2.com
etc
You'll need to add the new domains to data/private/conf/main.inc (SQ_CONF_SYSTEM_ROOT_URLS - one domain per line) as well.