Hi,
I am trying to map multiple sites in AEM6 each one to its own domain, and also have the path shortened automatically in both sides (e.g, from www.geometrixx.fr/*.html to /content/geometrixx/fr/*.html and have all the references in the returned page of the format /content/geometrixx/fr/* converted automatically to www.geometrixx.fr/*).
This is exactly the problem described in the link below:
http://www.cognifide.com/blogs/cq/multidomain-cq-mappings-and-apache-configuration/
The procedure as described in the link works well in a standalone installation of AEM, but when AEM is running inside an application server (JBoss7.1) only one side of the conversion works. The reverse side, i.e., the conversion from the content path like /content/site/xx.html to www.domain.com/xx.html don't work.
AEM is installed in the root context of the application server. Running JBoss7.1 at the port 8080 or 4502 don't make difference. The results are the same.
Anyone have an idea of the problem?
Below is the sling mapping definition.
{ "jcr:primaryType": "sling:OrderedFolder", "jcr:createdBy": "admin", "jcr:created": "Mon Sep 29 2014 15:23:52 GMT-0300", "geometrixx_fr": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Mon Sep 29 2014 15:23:52 GMT-0300", "sling:match": "geometrixx.fr.4502/$", "sling:internalRedirect": [ "/content/geometrixx/fr.html" ] }, "geometrixx.fr.4502": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Tue Sep 30 2014 16:02:27 GMT-0300", "sling:internalRedirect": [ "/content/geometrixx/fr" ], "redirect": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Tue Sep 30 2014 16:02:27 GMT-0300", "sling:match": "(.+)$", "sling:internalRedirect": [ "/content/geometrixx/fr/$1", "/$1" ] } }, "sergio_com_br": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Tue Sep 30 2014 16:02:27 GMT-0300", "sling:match": "sergio.com.br.4502/$", "sling:internalRedirect": [ "/content/portal/index.html" ] }, "sergio.com.br.4502": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Tue Sep 30 2014 16:02:27 GMT-0300", "sling:internalRedirect": [ "/content/portal" ], "redirect": { "jcr:primaryType": "sling:Mapping", "jcr:createdBy": "admin", "jcr:created": "Tue Sep 30 2014 16:02:27 GMT-0300", "sling:match": "(.+)$", "sling:internalRedirect": [ "/content/portal/$1", "/$1" ] } } }