Deployment

The instructions at www.macromedia.com/go/cfmx7_j2eecert provide detailed, application-server-specific ColdFusion MX 7 deployment instructions. Depending on your application server, the instructions describe deployment of an EAR file or WAR files in either a compressed archive or an expanded directory structure. When you deploy ColdFusion MX 7 on an existing version of JRun 4, you must expand the EAR file or WAR files manually before deployment.

The following procedures describe EAR and WAR deployment on an existing version of JRun 4.

Tip: The instructions for expanding the cfusion.ear file also apply when deploying ColdFusion MX 7 on BEA WebLogic.

Expanding and deploying an EAR file on JRun 4

Before you deploy ColdFusion MX 7 as an enterprise application on an existing JRun server, you must expand the EAR and the WAR files that it contains.

Note: If you are already using an application with an empty context root, you must use a context root other than / for the cfusion-ear file. If you specified / when you installed ColdFusion MX 7, you can change it by opening the cfusion-ear/META-INF/application.xml file in a text editor and modifying the context-root element. After you deploy the cfusion-ear file, you access ColdFusion pages by specifying http://hostname:portnumber/contextroot/pagename.cfm.

To deploy ColdFusion MX 7 as an enterprise application on JRun 4:

  1. Run the installation wizard for your platform, as described in Installing an EAR file or WAR files. Select the EAR option. When you get to the deployment step, return to these instructions.

    If you are updating an existing deployment of ColdFusion MX or ColdFusion MX 6.1 for J2EE, you must undeploy ColdFusion MX or ColdFusion MX 6.1 for J2EE before you deploy ColdFusion MX 7, as described in Updating from ColdFusion MX or ColdFusion MX 6.1 for J2EE.

  2. Expand the EAR file by performing the following steps:
    1. Open a console window, navigate to the directory that contains the EAR file, and make a new directory named cfusion-ear:
    2.     md cfusion-ear (mkdir cfusion-ear on UNIX)
      
    3. Change to the cfusion-ear directory and expand the cfusion.ear file with the jar command:
    4.     cd cfusion-ear
          java_home/bin/jar -xvf ../cfusion.ear
      

      This expands the cfusion.ear file into cfusion.war and rds.war (rds.war is not included if you specified a context root of / when you ran the installation wizard).

    5. In cfusion-ear, make a new directory named cfusion-war.
    6.     md cfusion-war (mkdir cfusion-war on UNIX)
      
    7. Change to the cfusion-war directory and expand the cfusion.war file with the jar command:
    8.     cd cfusion-war
          java_root/bin/jar -xvf ../cfusion.war
      

      This expands the cfusion.war file.

    9. (If rds.war exists) Go up one level to cfusion-ear, make a new directory named rds-war.
    10.     cd ..
          md rds-war (mkdir rds-war on UNIX)
      
    11. (If rds.war exists) Change to the rds-war directory and expand rds.war with the jar command:
    12.     cd rds-war
          java_root/bin/jar -xvf ../rds.war
      

      This expands rds.war.

    13. Go up one level to the cfusion-ear file, and delete the cfusion.war and rds.war files:
    14.     cd ..
          del cfusion.war (rm cfusion.war on UNIX)
          del rds.war (rm rds.war on UNIX)
      
    15. Open the cfusion-ear/META-INF/application.xml file in a text editor.
    16. Change the web-uri element from cfusion.war to cfusion-war (or the name of the directory that contains the expanded cfusion.war file). Change the web-uri element for rds.war to rds-war. A directory name in the web-uri element cannot contain a dot.
    17. Save the application.xml file.
  3. Deploy ColdFusion MX 7 by copying the cfusion-ear directory structure to the jrun_root/servers/servername directory. If auto deploy is enabled, JRun 4 either deploys the application immediately (if the JRun server is running), or when you start the JRun server.
  4. Review the server log (jrun_root/logs/servername-event.log) to ensure that ColdFusion MX 7 deployed successfully.

Expanding and deploying WAR files on JRun 4

When you deploy ColdFusion MX 7 as a web application on an existing JRun server, you expand the cfusion.war file, deploy it, and optionally modify the context root. For complete information on deploying ColdFusion MX 7 on JRun 4 as a WAR file, see www.macromedia.com/go/cfmx7_j2eecert.


View comments in LiveDocs