Prerequisites: To get the most from this article, understand these concepts and terms before reading: basic Core Utilities, configuration files, INSERT YOUR PREREQUISITES HERE |
Contents
- LH Scripts
- lh_config
-
lh_build
- lh_bootstrap
- lh_chroot
-
lh_binary
- lh_binary_chroot
- lh_chroot_*
- lh_binary_rootfs
- lh_binary_manifest
- lh_binary_encryption
- lh_binary_linux-image
- lh_binary_debian-installer
- lh_binary_memtest
- lh_binary_grub
- lh_binary_syslinux
- lh_binary_yaboot
- lh_binary_includes
- lh_binary_local-includes
- lh_binary_md5sum
- lh_binary_hdd
- lh_binary_iso
- lh_binary_net
- lh_binary_usb-hdd
- lh_chroot_*
- lh_source
- Debian Live
1. LH Scripts
Introduction
The lh_* scripts are helpers that do the work of making a debian-live image. Each helper script is given simple and specific task. This method of operation helps keep the debian-live system modular and configurable.
Overview
The live-helper build process involves calling two scripts, lh_config and lh_build. The job of lh_config is to make sure that the configuration files exist for the other lh_scripts to source. The next script to be called is the lh_build script. This script is responsible for calling all of the lh_* scripts that are responsible for creating and building a debian-live image.
2. lh_config
Introduction
Text for subsection A here...
subsection B
Text for subsection B here...
3. lh_build
Introduction
The lh_build script is a wrapper around four other helper scripts, which are themselves, wrappers around other helper scripts. These four scripts represent general steps in creating a debian-live image. These steps are bootstrap, chroot, binary, and source. The last step, source, is optional and isn't required to create a debian-live image.
3.1. lh_bootstrap
lh_bootstrap
The lh_bootstrap script is responsible for generating a very minimal system in the chroot directory. There are two scripts that are called by lh_bootstrap, lh_bootstrap_debootstrap and lh_bootstrap_cdebootstrap. Only one of these scripts is actually executed, and it creates the stage file .stage/bootstrap .
3.2. lh_chroot
lh_chroot
The lh_chroot script is a wrapper that calls a large amount of lh_chroot_* helper scripts.
3.2.1. lh_chroot_proc
The lh_chroot_proc script mounts or unmounts the proc filesystem in chroot/proc .
Requires
- stage/bootstrap
Stages
- stage/chroot_proc
3.2.2. lh_chroot_sysfs
The lh_chroot_sysfs script mounts or unmounts the sysfs filesystem in chroot/sys .
Requires
- stage/bootstrap
Stages
- stage/chroot_sysfs
3.2.3. lh_chroot_hosts
The lh_chroot_hosts script copies the hosts file from /etc/hosts to the chroot directory.
Requires
- stage/bootstrap
Stages
- stage/chroot_hosts
3.2.4. lh_chroot_resolv
The lh_chroot_resolv script copies the /etc/resolv.conf file to the chroot directory.
Requires
- stage/bootstrap
Stages
- stage/chroot_resolv
3.2.5. lh_chroot_sources
Requires
- stage/bootstrap
Stages
- stage/chroot_sources
3.3. lh_binary
lh_binary
The lh_binary script is a wrapper around a large amount of lh_binary_* helper scripts. It also calls some of the lh_chroot_* scripts before and after the lh_binary_* scripts are called.
3.3.1. lh_binary_chroot
The lh_binary_chroot helper creates a copy of the chroot directory and moves it to chroot/chroot . Successful execution of this script creates the stage file .stage/binary_chroot .
Requires
- stage/bootstrap
Stages
- stage/binary_chroot
3.3.2. lh_chroot_*
These lh_chroot_* scripts that are called at the beginning of the lh_binary step are to help prepare the chroot for generating the binary image. All of these scripts are given the argument "install" .
- lh_chroot_proc
- lh_chroot_sysfs
- lh_chroot_hosts
- lh_chroot_resolv
- lh_chroot_sources
3.3.3. lh_binary_rootfs
The lh_binary_rootfs script is responsible for creating the root filesystem for the binary image. It makes the image from the directory chroot/chroot . This script requires the stage files .stage/bootstrap and .stage/binary_chroot . This script creates the stage file .stage/binary_rootfs
Requires
- stage/bootstrap
- stage/binary_chroot
Stages
- stage/binary_rootfs
3.3.4. lh_binary_manifest
The lh_binary_manifest script creates files containing lists of the packages installed in the chroot directory.
Requires
- stage/bootstrap
Stages
- stage/binary_manifest
3.3.5. lh_binary_encryption
The lh_binary_encryption script will encrypt the rootfs image created by the lh_binary_rootfs script, provided that the rootfs sits on a loopback filesystem.
Requires
- stage/bootstrap
- stage/binary_rootfs
Stages
- stage/binary_encryption
3.3.6. lh_binary_linux-image
The lh_binary_linux-image script copies the kernel and initrd images into the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_linux-image
3.3.7. lh_binary_debian-installer
The lh_binary_debian-installer script installs the debian-installer into the binary directory. This script seems to be incomplete, currently.
Requires
- stage/bootstrap
Stages
- stage/binary_debian-installer
3.3.8. lh_binary_memtest
The lh_binary_memtest script will install either the memtest86 or memtest86+ package into the binary as a boot option.
Requires
- stage/bootstrap
Stages
- stage/binary_memtest
3.3.9. lh_binary_grub
The lh_binary_grub script installs the grub bootloader into the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_grub
3.3.10. lh_binary_syslinux
The lh_binary_syslinux script installs the syslinux bootloader into the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_syslinux
3.3.11. lh_binary_yaboot
The lh_binary_yaboot script installs the yaboot bootloader into the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_yaboot
3.3.12. lh_binary_includes
The lh_binary_includes script installs files from an "includes" directory into the binary directory. This script is only does something if the debian-installer option is enabled.
Requires
- stage/bootstrap
Stages
- stage/binary_includes
3.3.13. lh_binary_local-includes
The lh_binary_local-includes script installs files from the config/binary_local-includes directory to the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_local-includes
3.3.14. lh_binary_md5sum
The lh_binary_md5sum script generates a md5sums.txt file of all files underneath the binary directory.
Requires
- stage/bootstrap
Stages
- stage/binary_md5sum
3.3.15. lh_binary_hdd
The lh_binary_hdd is the last step in creating a binary image. This script will build a binary image for a hard disk.
Requires
- stage/bootstrap
Stages
- stage/binary_hdd
3.3.16. lh_binary_iso
The lh_binary_iso is the last step in creating a binary image. This script will create an iso image for making live cdroms.
Requires
- stage/bootstrap
Stages
- stage/binary_iso
3.3.17. lh_binary_net
The lh_binary_net is the last step in creating a binary image. This script will create a gzipped tar file to be used over a network.
Requires
- stage/bootstrap
Stages
- stage/binary_net
3.3.18. lh_binary_usb-hdd
The lh_binary_usb-hdd is the last step in creating a binary image. This script will create an image ready to be dd'ed to a usb flash card.
Requires
- stage/bootstrap
Stages
- stage/binary_usb-hdd
3.3.19. lh_chroot_*
These lh_chroot_* scripts that are called at the end of the lh_binary step are to help ...(finish me)
- lh_chroot_resolv
- lh_chroot_hosts
- lh_chroot_sysfs
- lh_chroot_proc
3.4. lh_source
lh_source
Text for subsection B here...
