Tille's SiteEnter this script as a post-installation script in the /export/config/rules file for enabling use of apropos and man -k.
#!/sbin/sh # This will make an index of man pages every night. echo "2 2 * * * catman -w" >> /a/var/spool/cron/crontabs/root
The default sshd_config file does not allow root logins. Using sed, this script changes the offending configuration directive:
#!/bin/bash
if [ -f /a/etc/ssh/sshd_config ]
then
sed -e 's/^PermitRootLogin no/PermitRootLogin yes/' /a/etc/ssh/sshd_config > /tmp/sshtemp
mv /tmp/sshtemp /a/etc/ssh/sshd_config
fi
Apache does not start if you don't give proof that you read the config file. At least you need to specify a hostname for your webserver. This is a way to do that:
#!/bin/bash
cp ${SI_CONFIG_DIR}/file_repository/httpd.conf /a/etc/apache
HOSTNAME=$(uname -n)
sed -e "s/armadillo/$HOSTNAME/" < /a/etc/apache/httpd.conf > /tmp/httpd.conf.new
cat /tmp/httpd.conf.new > /a/etc/apache/httpd.conf
If you need to do more than one post-installation configuration, have the rules file point to a script that will execute all scripts in a directory. This is an example:
#!/sbin/sh for i in postinstall-scripts/* do sh $i done
| Home |