Multiple domains to accommodate localization of national site



I've read the many articles and discussion topics about mapping multiple domains but I haven't found a discussion that explicitly addresses my use case, which I think would be fairly common so I'm going to bring it up.

I have a global site that's been localized and translated into various languages. Some places in the world want / need to use a different domain. I'd like to set up my content repository like this:

/content/globalsite/us/en -->www.globalsite.com/us/en

/content/globalsite/mx/es -->www.globalsite.com/mx/es




How can the above mappings be done in AEM? or am I forced into creating a separate /content node for each country that does not use the globalsite.com domain? Our current deployment is breaking out each domain into its own node under /content, but it is making the AEM interface very convoluted for our authors. It would be much nicer to have all of those global sites under a common node so they can be easily grouped group.






You can achieve this by using multiple vhost and farm configurations at the dispatcher level. Check [1] on how to setup multidomain URL's

[1] Using Dispatcher with Multiple Domains




I reviewed that document (Using Dispatcher with Multiple Domains) prior to posting and all of the examples showed mappings where they assumed each domain had its own node under /content.






Is it possible to use multiple vhost and farm configurations at the dispatcher level to get the node structure I am trying to get? It's not clear from the documentation that this is possible.




You can have different vhost entries for each domain and write rewrite rules to direct traffic to the nodes you want