Documentation Archive Developer
Search
PATH  Documentation > WebObjects 4.5 > Deploying WebObjects Applications

   

Installing Applications

You can use the developer application Project Builder to deploy WebObjects applications. When an application is ready to be deployed, do the following in Project Builder:

  1. Click the inspector button to open the Build Attributes Inspector. In the Install in field, type the path to the directory in which the application is to be installed, such as $(LOCAL_LIBRARY_DIR)/WebObjects/Applications .
  2. If you're installing a framework,
    type $(LOCAL_LIBRARY_DIR)/Library/Frameworks

    Note:You'll need write permission for the directory into which the application is to be installed in order for the build to succeed.

  3. If your project contains web server resources, go to the Makefile.preamble file under Supporting Files. Uncomment the following macro:
  4. INSTALLDIR_WEBSERVER

    Note:You'll need write permission for the WebServer's doc root in order for such a "split install" to succeed.

  5. In the Project Build panel, click the check-mark button to bring up the Build Options panel.
  6. Choose install as the build target, and close the Build Options panel.
  7. Click the Build button to start the build and installation process.

Assuming that your application is named MyApp.woa , and that you installed your application in LOCAL_LIBRARY_DIR /WebObjects/Applications , the following directories will be created:

LOCAL_LIBRARY_DIR /WebObjects/Applications/MyApp.woa
  MyApp[.exe]

  Resources/

  WebServerResources/


DOC_ROOT /WebObjects/MyApp.woa

  WebServerResources/

When the client tries to contact an application, the adaptor first looks for a configuration file that names the application, and then for an executable in   DOC_ROOT /WebObjects and   NEXT_ROOT /Library/WebObjects/Applications . Thus, you can install the entire directory under   DOC_ROOT /WebObjects . However, doing so presents a security problem if you have scripted components, since any client can access any file under the document root. This means that if you install scripted components under the document root, you're exposing source code to outside users.

Instead, it is recommended that you do a "split install", installing most of the application in   NEXT_ROOT /Library/WebObjects/Applications and install only the web server resources under the document root. It is also recommended that you install the application directly in the   DOC_ROOT /WebObjects directory rather than in a subdirectory. If you install in a subdirectory, your application will still run but won't find image files unless you explicitly provide the application's base URL (WOApplicationBaseURL). For more information, see Starting Up Applications From the Command Line.

 


© 1999 Apple Computer, Inc. – (Last Updated 25 August 99)