[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Is it possible to have squashfs inside initrd?



Am 20.09.2014 um 14:21 schrieb Daniel Lindgren:
> That is one way to go, but that would also mean managing 60+ different
> configuration files instead of one, or at least creating and maintaining
> a script to generate new config files with every "master" update. Easy
> to forget to run the script after update, there are several people
> involved in PXELINUX changes and I would like a more "foolproof"
> solution, if possible. I would be the only one updating squashfs/initrd,
> that would eliminate some of the fools ... ;)

I'm not sure how far your http-instead-of-tftp-trickery goes, but if the
search mechanism employed by pxelinux is also tricked into using http,
then you could use symlinks pointing to the same file, and have your
webserver *execute* said file (which in turn generates the required
output) instead of delivering its content.

That way, you could have one static template and the script would insert
the required IP when it is called.  (The script will detect under which
name it was called and behave accordingly.)

If that doesn't work, use a template and a special editing script that
calls $EDITOR /foo/bar/template and does the right things after the
editor process terminates. Make that script place a "# AUTOGENERATE FILE
- DO NOT EDIT BY HAND - USE $COMMAND INSTEAD" warning at the top of each
generated file.  Not the most elegant solution, but hey, life aint no
pony farm.

-Stefan


Reply to: