PhenixID

PSD1099 – Run multiple web apps in IM 5.x

Summary

This PhenixID Solution Document (PSD) is written for PhenixID Identity Manager 5.x.

By default IM 5.x ships with one application, customer. The customer application is the app where customer can add custom data specific application. Customer running several IM web application and would like them to run in the same installation as the customer web app.  There can also scenarios where someone like to rename the customer folder to something else.

System Requirements

  • PhenixID Identity Manager 5.x installed

Overview

By default IM 5.x ships with one application, customer. The Tomcat configuration pointing to the customer app is added in the server.xml file in the server folder. If you scroll to the end of the file you can see the configuration of the default app customer. If you like to have one or more web apps on the same running in the same Tomcat on the same server you just add more section for each web app. Every time you upgrade IM to a newer version you need to add the section(s) again, this will not be handled by the installer.

Add another web app to IM 5.x

Create a new web app

Add a new web app to the drive:\..\PhenixID\IM\ (the web app name can NOT have the same name as any existing)
In this example:

  • Folder name of the new web app is c2 (drive:\..\PhenixID\IM\c2)
  • Web address to is im2 (http://server/im2)

Add info about new app in server.xml

  1. Open server.xml (drive:\..\PhenixID\IM\server\conf)
    Scroll to the bottom of the file
  2. The web app created during the installation called\customer (addressed as /im) configuration looks like below
    <Context docBase="C:\Program Files\PhenixID\IM/application" path="/im">
     <Resources allowLinking="true">
     <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/customer/config" webAppMount="/WEB-INF/NEIDMgmt/" />
     <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/customer/extension/web" webAppMount="/" />
    <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/customer/extension/lib" webAppMount="/WEB-INF/lib" />
     <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/customer/extension/class" webAppMount="/WEB-INF/classes" />
     </Resources>
    </Context>
  3. Copy the section above and paste just below the end of the section
  4. Change /im to /im2 (or whatever name you have)
  5. Change /customer to /c2 (or whatever name your web app have)
  6. When change it should look like below
    <Context docBase="C:\Program Files\PhenixID\IM/application" path="/im2">
     <Resources allowLinking="true">
     <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/c2/config" webAppMount="/WEB-INF/NEIDMgmt/" />
    <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/c2/extension/web" webAppMount="/" />
    <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/c2/extension/lib" webAppMount="/WEB-INF/lib" />
    <PostResources className="org.apache.catalina.webresources.DirResourceSet"
     base="C:\Program Files\PhenixID\IM/c2/extension/class" webAppMount="/WEB-INF/classes" />
     </Resources>
    </Context>
  7. Save server.xml

Modify file paths in DSEditor.properties

  1. Open DSEditor.properties in drive:\..\PhenixID\IM\c2\config
  2. Run Find and Replace for customer to c2
  3. Save DSEditor.properties

Modify file path in log4j2.xml

To get separate logging in im2 & audit to each customer, this file must be modified.

  1. Open log4j2.xml in drive:\..\PhenixID\IM\c2\extension\class
  2. Run Find and Replace for customer to c2
  3. Save log4j2.xml

Start service and verify new app

Start the IM service and browse to http://server/c2.

If you like to add more application just do as above.


DISCLAIMER
Information provided in this document is for your information only. PhenixID makes no explicit or implied claims to the validity of this information. Any trademarks referenced in this document are the property of their respective owners.

The origin of this information may be internal or external to PhenixID. PhenixID makes all reasonable efforts to verify this information.

PhenixID - support.phenixid.se