Sun Java System Portal Server 7 Community Sample Guide

Deploying the Wiki Portlet

This section includes instructions for deploying and editing the wiki portlet after the Portal Server installation. After Portal Server is installed, portlets (available for deployment) are in the PortalServer-base/portletapps/portletname directory. If Portal Server has been configured, the portlet application will be in PortalServer-DataDir/portals/portal-ID/portletapps/portletapp directory. If Portal Server has not been configured, you must manually copy the files to the PortalServer-DataDir/portals/portal-ID/portletapps/portletapp directory before deploying the portlet.

ProcedureTo Deploy the Portlet

Steps
  1. Log in to the Portal Server host and change directories to where the portlet application is located.

    The wiki portlet is in the PortalServer-DataDir/portals/portal-ID/portletapps/wiki directory.

  2. Create the portlet WAR file.

    To create the WAR file:

    1. Edit the tokens.properties file to specify customizable parameters for the portlet.

      See Appendix B, Tokens for Wiki Portlet for more information.

    2. Run ant customize.

      Ensure that JavaTM DB is running before running ant.

  3. Deploy the Portlets.

    1. Create a file containing the password of the amadmin user. For example, type, echo mypassword >/tmp/ampasswd.

    2. Type /opt/SUNWportal/bin/psadmin deploy-portlet -u amadmin -f /tmp/ampassword -p myPortal -v -i myInstance -g --userinfofile FULL_PATH_TO_userInfoMapping.properties FULL_PATH_TO_wiki.war_FILE.

    3. Restart the container.

  4. Log in and verify that the wiki portlet is deployed.

    1. Go to http://HOST:PORT/portal/dt and select sample where you deployed the wiki portlet.

    2. Log in to the sample and view the portlet.

ProcedureTo Enable Wiki Portlet to Display Channels and/or Portlets

Step

    The wiki portlet must be the first selected element of a DynamicAggregationContainer. The display profile of the Developer Sample desktop and of the sample wiki community include such a container. The wiki portlet can display and aggregate any channel or portlet that is in the available list of the DynamicAggregationContainer. If a channel is not in the available list, it will not appear on the page with no error or other indication. This allows the wiki portlet to include different channels for different users based on their display profiles.