FAI repo configuration
George VerDuin
gfv2008-home at yahoo.com
Mon Dec 23 22:49:28 CET 2013
Greetings
This note is a request for review to anyone with time and interest, with
a test patch to apply if all goes well. Given that I am fairly new to
the fai community, I would like to focus ONLY on the provision of
repositories for use by server and client. Using FAI provided
"demohost" the concepts below were tested successfully. Only FAI 4.0.8
and wheezy are considered here thus I request any review to include all
other familiar environments as well.
What I see in apt are two things not fully integrated into FAI.
1. The /etc/apt/sources.list.d/ directory is provided for inclusion of
addendum repository source lists, notably projects like FAI. The
inclusion of a "fai.list" file in the directory negates the need to
insert FAI into "sources.list" file by editor.
2. The use of proxy server by an addition to /etc/apt/apt.conf.d/
directory. Apt documentation recommends the inclusion of a file
"02proxy" to enable repository access through a proxy server.
Recently in conversation with Thomas Lange, we agreed that a custom hook
would achieve instantiation of the proxy feature. We did not discuss
the sources.list.d/ feature that another hook could install. In
beginning to write a "How To" document it occurred to me that both of
these features might be best installed in the main stream application.
Thus I patched /usr/lib/fai/subroutines to achieve both objectives
without custom hooks.
So just for sake of argument, let's assume the patch is installed. To
supply repositories, all work is done in the /etc/fai/apt/ directory.
Now the "sources.list" may be identical to the file provided by any
Distro. I see it as an advantage to use the Distro-supplied file. Now
to access the FAI project source, install the file "fai.list" into the
sources.list.d/ directory. Others as well if needed. Now to actuate a
proxy, install the "02proxy" into the apt.conf.d/ directory. Only if a
need to make exception to these files is a hook required. Should this
concept be accepted, then the approach is so simple no "How-To" document
is useful.
The patch is only for FAI4.0.8 file "subroutines". The patch is to be
inserted following line #957. To verify the location, the attached text
includes the line-before and the line-after commands that will need to
be deleted to prevent duplication. I provide it only for testing
convenience if anyone cares to go that far. Should this concept be
accepted I will submit a formal patch in the regular channels.
In the spirit of full disclosure, I see two scripts named "FAISERVER"
and "LAST" that also partly apply the above. I do not fully understand
the basis for these scripts yet and I will continue my search. It is
possible these scripts might undergo some change.
Of course I will use this for my own work, but I will not go further
unless there is a positive response from FAI users. Thanks in advance
for any review of this concept, I do hope it might simplify FAI slightly.
Regards
George
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.uni-koeln.de/pipermail/linux-fai/attachments/20131223/49e01bd0/attachment.html>
-------------- next part --------------
fcopy -BMv /etc/apt/sources.list || cp -v $FAI_ETC_DIR/apt/sources.list $FAI_ROOT/etc/apt
# Add project sources and proxy into the copy to preserve repo source config -- GFV 2013.12.23
fcopy -BMv /etc/apt/apt.conf.d/02proxy || cp -v $FAI_ETC_DIR/apt/apt.conf.d/02proxy $FAI_ROOT/etc/apt/apt.conf.d
fcopy -BMv /etc/apt/sources.list.d || cp -v $FAI_ETC_DIR/apt/sources.list.d/* $FAI_ROOT/etc/apt/sources.list.d
# End add by GFV
if fcopy -BMv /etc/apt/preferences; then
More information about the linux-fai
mailing list