0 Replies Latest reply on Oct 11, 2011 7:43 AM by aldjinn

    Restrict applications to certain domains

    aldjinn Newbie

      Hi,

      I'm currently testing a migration from JBoss 5.1 and mod_jk to JBoss 7 in domain mode and mod_cluster. This is working fine in general, but I'm not able to restrict applications to certain domains.

       

      I've got two applications: app1 and app2. Both can be accessed directly from the JBoss servers with http://localhost:8080/app1 and http://localhost:8080/app2. mod_cluster listens to port 80 on localhost, so both application can be accessed by http://localhost/app1 and http://localhost/app1.

       

      Now I want to add two VirtualHosts (domain1 and domain2) and app1 should only be accessible by http://domain1/app1 but not http://domain2/app1 and vice versa.

       

      <VirtualHost *:80>

          DocumentRoot ./htdocs

          ServerName domain1:80

          ErrorLog logs/domain1-error_log

          CustomLog logs/domain1-access_log combined

          LogLevel debug

       

          ProxyPass / balancer://mycluster stickysession=JSESSIONID|jsessionid nofailover=On

          ProxyPassReverse / balancer://mycluster

      </VirtualHost>

       

      In the old mod_jk configuration, JkMount and JkUnMount are used to bind/unbind apps from/to domains.

       

      Any idea or hints?