Este contenido no está disponible en el idioma seleccionado.
1.6. Pre-installation Script
You can add commands to run on the system immediately after the
ks.cfg has been parsed. This section must be at the end of the kickstart file (after the commands) and must start with the %pre command. You can access the network in the %pre section; however, name service has not been configured at this point, so only IP addresses work.
Note
Note that the pre-install script is not run in the change root environment.
--interpreter /usr/bin/python- Allows you to specify a different scripting language, such as Python. Replace /usr/bin/python with the scripting language of your choice.
1.6.1. Example Copiar enlaceEnlace copiado en el portapapeles!
Copiar enlaceEnlace copiado en el portapapeles!
Here is an example
%pre section:
This script determines the number of hard drives in the system and writes a text file with a different partitioning scheme depending on whether it has one or two drives. Instead of having a set of partitioning commands in the kickstart file, include the line:
%include /tmp/part-include
%include /tmp/part-include
The partitioning commands selected in the script are used.
Note
The pre-installation script section of kickstart cannot manage multiple install trees or source media. This information must be included for each created ks.cfg file, as the pre-installation script occurs during the second stage of the installation process.