Feature #39293
closedAllow custom pre-install script in kickstart default template
Description
Currently, custom snippets are possible for the %pre and %post sections of the kickstart default template. However, nothing for the %pre-install section is supported, i.e. if you need something in the pre-install section during kickstart you need to clone the kickstart default template and modify it. Which then means you have to track later changes of the default template and add them to the modified one.
The pre-install section runs after the pre section before the actual installation. At that time the file system has been set up. This allows you to drop in specific configuration files which are used during installation. We use this to drop in a /etc/login.defs file with modified {SYS_,}{UID,GID}-{MIN_MAX} values so that all locally allocated uids and gids are below 1000 as historically we use id numbers from 1000 in our ldap. So we use 201-499 for local system ids and 500-999 for local user ids.
Without the pre-install drop-in system services allocate id numbers 999 going down.
I am pretty sure we are not the only ones who use the %pre-install section during kickstart.
We currently add
%pre-install --interpreter=/usr/bin/bash <%= snippet_if_exists(template_name + " custom pre-install") %> <%= section_end %>
(I didn't find a condition to check if the custom pre-install snippet exists and then make the whole thing a conditional section.)
Updated by The Foreman Bot about 1 month ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/10976 added
Updated by The Foreman Bot 2 days ago
- Pull request https://github.com/theforeman/foreman/pull/11022 added
Updated by Anonymous 1 day ago
- Status changed from Ready For Testing to Closed
Applied in changeset foreman|b9005f4e825789246c569084fd8efb1d5237adc0.