Rename
$JBOSS_HOME/server/default/deploy/ext.ear/portal-web-complete.war
to portal-web-alpha.war
.
Copy
$JBOSS_HOME/server/default/deploy/ext.ear/portal-web-alpha.war
to portal-web-beta.war
.
Edit
$JBOSS_HOME/server/default/deploy/ext.ear/portal-web-alpha.war/WEB-INF/web.xml
and change the value of the company id to
alpha.com.
<context-param> <param-name>company_id</param-name> <param-value>alpha.com</param-value> </context-param>
On startup, the portal will create the necessary database
entries and create a default user account with
test@alpha.com
as the login and
test
as the password.
Repeat this step for
$JBOSS_HOME/server/default/deploy/ext.ear/portal-web-beta.war/WEB-INF/web.xml
but replace alpha.com with
beta.com.
Edit $JBOSS_HOME/server/default/deploy/ext.ear/portal-web-alpha.war/WEB-INF/jboss-web.xml to add the context root and virtual host.
<jboss-web> <security-domain>java:/jaas/PortalRealm</security-domain> <context-root>/</context-root> <virtual-host>www.alpha.com</virtual-host> ... </jboss-web> Repeat this step for /server/default/deploy/ext.ear/portal-web-beta.war/WEB-INF/jboss-web.xml but replace alpha.com with beta.com.
Edit
$JBOSS_HOME/server/default/deploy/ext.ear/META-INF/application.xml
.
Remove the old reference to
portal-web-complete.war
and add the
references to portal-web-alpha.war
and
portal-web-beta.war
.
<module> <web> <web-uri>portal-web-alpha.war</web-uri> <context-root>/</context-root> </web> </module> <module> <web> <web-uri>portal-web-beta.war</web-uri> <context-root>/</context-root> </web> </module>
Edit
$JBOSS_HOME/server/default/deploy/jbossweb-tomcat50.sar/server.xml
to add the alpha and beta hosts.
<Engine name="jboss.web" defaultHost="www.alpha.com"> ... <Host name="www.alpha.com" ... ... <DefaultContext cookies="true" crossContext="true" override="true" /> </Host> <Host name="www.beta.com" ... ... <DefaultContext cookies="true" crossContext="true" override="true" /> </Host> </Engine>
Start JBoss+Tomcat and access the portals with your browser
at http://www.alpha.com and
http://www.beta.com
. Your user login and
password combinations are
test@alpha.com/test
and
test@beta.com/test
.