There can be only one request script per package and it must be named request.
The environment variable assignments should be added to the installation environment for use by the pkgadd command and other packaging scripts by writing them to the response file (known to the script as $1).
System environment variables and standard installation environment
variables, except for the CLASSES
and BASEDIR
parameters, cannot
be modified by a request script. Any of the other environment
variables you created can be changed.
A request script can only modify the BASEDIR
parameter starting with the Solaris
2.5 and compatible releases.
Every environment variable that the request script may manipulate should be assigned a default value in the pkginfo file.
The format of the output list should be PARAM=value. For example:
CLASSES=none class1 |
The administrator's terminal is defined as standard input to the request script.
Do not perform any special analysis of the target system in a request script. It is risky to test the system for the presence of certain binaries or behaviors, and set environment variables based upon that analysis, because there is no guarantee that the request script will actually be executed at install time. The administrator installing the package may provide a response file that will insert the environment variables without ever calling the request script. If the request script is also evaluating the target file system, that evaluation may not happen. An analysis of the target system for special treatment is best left to the checkinstall script.
If it is possible that the administrators who will be installing your package will be using the JumpStartTM product, then the installation of your package must not be interactive. This implies that either you should not provide a request script with your package, or you need to communicate to the administrator that they should use the pkgask command, prior to installation, to store their responses to the request script. For more information on the pkgask command, see pkgask(1M).