Pre-install scripts - Red Hat Linux
Use the Pre-Install Scripts tab in the Red Hat Linux system package to provide custom scripts for disk cleanup, hardware configuration, disk array configuration, and pre-disk partitioning.
echo "Pre PARTED partitions" >> /root/log.txt parted /dev/sda print >> /root/log.txt #Remove all existing partitions echo "Creating new partition table" >> /root/log.txt parted /dev/sda mklabel gpt parted /dev/sda print >> /root/log.txt
To add a pre-install script, click Add, then specify the script's name, contents, and whether or not to reboot after the script is executed.
Network-enabled Gentoo scripting
A Gentoo agent is used for provisioning servers when you create Gentoo-based Linux system packages. When writing scripts for the Pre-Install Scripts and Post-Disk Partition options, you can use the full functionality of Gentoo batch scripting. Enter any Gentoo-based command in the text box. When your script runs as part of the provisioning process, it is network-enabled, meaning you can map network drives and execute Gentoo commands over those mapped drives. The following is an example of some custom commands used for disk cleanup in a Pre-Install Script:
mkdir ~/blprov cd ~/blprov wget* *[http://supwin2k3serv2/pxestore/utility/someutility]* *chmod 700 ./someutility
Proceed to the Disk partition - Red Hat Linux tab.