- Document how to install packages for a NanoBSD image

PR:		docs/115732
Submitted by:	John Ferrell <jdferrell3@yahoo.com>
This commit is contained in:
Gabor Kovesdan 2007-12-21 21:19:54 +00:00
parent 4b41ca41df
commit 9bc967e5e2
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/head/; revision=31140

View file

@ -325,6 +325,23 @@ customize_cmd cust_etc_size</programlisting>
</itemizedlist>
</sect3>
<sect3>
<title>Adding packages</title>
<para>Packages can be added to a <application>NanoBSD</application>
image using a custom function. The following fuction will install
all the packages located in
<filename>/usr/src/tools/tools/nanobsd/packages</filename>:</para>
<programlisting>install_packages () (
mkdir -p ${NANO_WORLDDIR}/packages
cp /usr/src/tools/tools/nanobsd/packages/* ${NANO_WORLDDIR}/packages
chroot ${NANO_WORLDDIR} sh -c 'cd packages; pkg_add -v *;cd ..;'
rm -rf ${NANO_WORLDDIR}/packages
)
customize_cmd install_packages</programlisting>
</sect3>
<sect3>
<title>Configuration file example</title>