Listing 2: install-basics
#! /bin/sh
#
# install-basics: Written 13APR95 by Michael Hill
# @(#) install a few basic files on a client
#
PATH=/bin:/usr/bin
if [ $# -eq 0 ]; then
echo "usage: `basename $0` <client-name> [...]" >&2
exit 1
fi
for client
{
rcp /.bashrc /.bash_profile /.bash_logout ${client}:/
rcp /.inputrc /.exrc ${client}:/
if [ "$?" -ne 0 ]; then
echo "Operation failed for $client. Make sure \c"
echo "$HOST is in $client's /.rhosts file." >&2
continue
fi
rcp /etc/shells /etc/syslog.conf ${client}:/etc
rcp /etc/hosts.equiv /etc/sudoers ${client}:/etc
rcp /etc/init.d/screen /etc/init.d/misc \
${client}:/etc/init.d
echo "Installation of $client complete."
echo "Please run /usr/local/share/bin/initialize-client on $client."
}
exit 0
# End of File
|