How to add partitions to kickstart file with python

Jason L Tibbitts III tibbs at math.uh.edu
Wed Aug 5 17:27:15 UTC 2015


>>>>> "PH" == Petr Hracek <phracek at redhat.com> writes:

PH> Is there any way how to add this data to kickstart file?

I get the feeling that you know all of what I'm writing and that your
question is much more complicated than the one I'm answering, but
anyway....

You can just generate what you need in %pre, write that to /tmp in
a format that pykickstart understands, and use %include in your
kickstart file.

My disk layout code is relatively complicated and all done in %pre, but
it's written in bash.  You can try using %pre --interpreter
/usr/bin/python, which should work, but I don't know what set of modules
are available.

Examples are at
https://github.com/rhinstaller/pykickstart/blob/master/docs/kickstart-docs.rst#pre-install-script

PH> How can I read commented data from kickstart file generated by
PH> anaconda?

I'm not sure what you mean by commented data.  Things pulled in with
%include can include comments, no different from data that's directly in
%the kickstart file.

 - J<




More information about the Kickstart-list mailing list