admenviron(5)

NAME
admenviron - administrative script environment

DESCRIPTION
When an AminSuite application runs one of the user supplied scripts, the application makes available a set of environment variables; see environ(5). These environment variables provide a way to make information about the specific administrative operation available to the script. Currently only the User Manager and Host Manager allow a user to specify a script.

The following environment variables will be set in the environment of the scripts for both the User Manager and the Host Manager.

ADM_OPERATION
    The administrative operation for which this script is being called. The possible values are PREADD, POSTADD, PREMOD, POSTMOD, PREDEL and POSTDEL.

PATH
    /usr/sbin:/usr/bin

The following environment variables are specific either to the User Manager or the Host Manager. The variables that have the prefix ADM_CLIENT will only be set for scripts that are run from the Host Manager while variables that have the prefix ADM_USER will only be set for scripts that are run from the User Manager.

ADM_CLIENT_HOSTNAME
    The name of the host that the operation is being performed on.

ADM_CLIENT_IP_ADDR
    The IP address of the host that the operation is being performed on.

ADM_CLIENT_ETHERNET_ADDR
    The Ethernet address of the host that the operation is being performed on.

ADM_CLIENT_ARCHITECTURE
    The architecture of the AutoClient that the operation is being performed on. The possible values are sparc, i386 or ppc.

ADM_CLIENT_MACHINE
    The platform of the AutoClient that the operation is being performed on. For example, sun4m.

ADM_CLIENT_OS_NAME
    The name of the operating system for the AutoClient. The only currently supported value is Solaris.

ADM_CLIENT_OS_VERSION
    The version of the operating system for the AutoClient. For example, 2.5.1.

ADM_CLIENT_ROOT
    The path on the server to the AutoClient's root area that the operation is being performed on. For example, /export/root/testhost.

ADM_CLIENT_SWAPSIZE
    The swap size, in megabytes, of the AutoClient that the operation is being performed on. For example, 32, which indicates 32MB is the swap size.

ADM_CLIENT_DISKCONF
    The disk configuration of the AutoClient that the operation is being performed on. For example, 1disk.

ADM_CLIENT_DISCONN
    The state of the disconnectable option for the AutoClient that the operation is being performed on. The possible values are Y and N.

ADM_CLIENT_TIMEZONE
    The timezone of the host that the operation is being performed on. For example, US/Eastern.

ADM_CLIENT_TYPE
    The system type of the host that the operation is being performed on. The possible values are STANDALONE, AUTOCLIENT or GENERIC.

ADM_CLIENT_SERVER
    The name of the server on which the AutoClient's root lives.

ADM_USER_LOGIN_NAME
    The user name of the account being manipulated. For example, newuser.

ADM_USER_UID
    The user ID of the account being manipulated. For example, 2001.

ADM_USER_PRIMARY_GROUP
    The primary group of the account being manipulated. For example, 120.

ADM_USER_SHELL
    The login shell of the account being manipulated. For example, /bin/sh.

ADM_USER_HOMEPATH
    The home directory of the account being manipulated. For example, /export/home/newuser.

ADM_USER_SERVER
    The name of the server on which the user's home directory lives. For example, home_server.

ADM_USER_SKELETON_PATH
    The path to the skeleton files used when creating a new account. For example, /etc/skel.

ADM_USER_FILEMODE
    The permissions the user's home directory gets created with. For example, 0755.

ADM_USER_NAMESERVICE
    The name service selected the updates be applied to. For example ufs, nis, or nis_plus.

ADM_USER_AUTOMOUNT_HOME
    Edit the autohome map for the account being manipulated. Either TRUE or FALSE.
If the script exits with a non-zero exit status, this causes the specified operation to fail. In this case, no changes will be made. The one exception to this is that a non-zero exit status from the POSTDEL script does not restore the system state.

NOTES
The environmental variables passed to a script from the Host Manager have values of the form:
    original_value[,new_value]
where original_value is the original value while new_value is the optional new, or modified value. For example if you are converting a standalone to an AutoClient, the ADM_CLIENT_TYPE variable would have a value of STANDALONE,AUTOCLIENT since STANDALONE is the original client type and AUTOCLIENT is the new client type. In this same example the value of ADM_CLIENT_DISKCONF might be ,1disk where the empty string is the original value and 1disk is the new value. If converting from an AutoClient to a standalone, ADM_CLIENT_DISKCONF might be 1disk, where the original value is 1disk and the new value is the empty string.

SEE ALSO
admhostadd(1m), admhostmod(1m), admhostdel(1m)