#!/bin/sh
#
# Copyright (c) 2001 by Sun Microsystems, Inc.
# All rights reserved.
#
#ident	"@(#)preinstall	1.10	01/05/23 SMI"
#
# Add the spmadmin user to the system

PROG=SUNWscvr.preinstall

/usr/sbin/chroot ${PKG_INSTALL_ROOT:-/} /usr/sbin/useradd -d / -s /usr/bin/pfsh spmadmin

if [ $? -ne 0 ]
then
    echo "${PROG}: Failed to add the spmadmin user to the system"
fi

# exit 0 so that the pkgadd will always succeed
exit 0
