home *** CD-ROM | disk | FTP | other *** search
/ Best Tools for JAVA / Best Tools for JAVA.iso / JAVA_ALL / RMI_OS / RMI-PREB / SOLARIS / JAVA-RMI.CGI
Encoding:
Text File  |  1996-10-16  |  1.9 KB  |  58 lines

  1. #!/bin/sh
  2. #
  3. # This script executes the Java interpreter, defines properties
  4. # that correspond to the CGI 1.0 environment variables, and executes
  5. # the class "sun.rmi.transport.proxy.CGIHandler".  It should be
  6. # installed in the directory to which the HTTP server maps the
  7. # URL path "/cgi-bin".
  8. #
  9. # (Configuration is necessary as noted below.)
  10. #
  11. # This class will support a QUERY_STRING of the form "forward=<port>"
  12. # with a REQUEST_METHOD "POST".  The body of the request will be
  13. # forwarded (as another POST request) to the server listening on the
  14. # specified port (must be >= 1024).  The response from this forwarded
  15. # request will be the response to the original request.
  16. #
  17. # CONFIGURATION:
  18. #
  19. # Fill in correct absolute path to RMI classes below.  For example,
  20. # the "CLASSPATH=" line might be changed to the following if RMI is
  21. # installed at the "rmi" subdirectory of user "mylogin"'s home
  22. # directory:
  23. #
  24. # CLASSPATH=/home/mylogin/rmi/lib/classes.zip
  25. #
  26. CLASSPATH=/export/home/pjones/rmi-prebeta/classes
  27. export CLASSPATH
  28. #
  29. # CONFIGURATION:
  30. #
  31. # Fill in correct absolute path to Java interpreter below.  For example,
  32. # the "PATH=" line might be changed to the follow if the JDK is installed
  33. # at the path "/usr/local/java":
  34. #
  35. # PATH=/usr/local/java/bin:$PATH
  36. #
  37. PATH=/opt/java1.0.2/bin:$PATH
  38. java \
  39.     -DAUTH_TYPE="$AUTH_TYPE" \
  40.     -DCONTENT_LENGTH="$CONTENT_LENGTH" \
  41.     -DCONTENT_TYPE="$CONTENT_TYPE" \
  42.     -DGATEWAY_INTERFACE="$GATEWAY_INTERFACE" \
  43.     -DHTTP_ACCEPT="$HTTP_ACCEPT" \
  44.     -DPATH_INFO="$PATH_INFO" \
  45.     -DPATH_TRANSLATED="$PATH_TRANSLATED" \
  46.     -DQUERY_STRING="$QUERY_STRING" \
  47.     -DREMOTE_ADDR="$REMOTE_ADDR" \
  48.     -DREMOTE_HOST="$REMOTE_HOST" \
  49.     -DREMOTE_IDENT="$REMOTE_IDENT" \
  50.     -DREMOTE_USER="$REMOTE_USER" \
  51.     -DREQUEST_METHOD="$REQUEST_METHOD" \
  52.     -DSCRIPT_NAME="$SCRIPT_NAME" \
  53.     -DSERVER_NAME="$SERVER_NAME" \
  54.     -DSERVER_PORT="$SERVER_PORT" \
  55.     -DSERVER_PROTOCOL="$SERVER_PROTOCOL" \
  56.     -DSERVER_SOFTWARE="$SERVER_SOFTWARE" \
  57.     sun.rmi.transport.proxy.CGIHandler
  58.