DOKK / manpages / debian 11 / live-build / live-build.7.ja
LIVE-BUILD(7) Debian Live Project LIVE-BUILD(7)

名前

live-build - the Debian Live tool suite

概要

lb {-h|--help|-u|--usage|-v|--version}

lb COMMAND [OPTIONS]

説明

live-build は Live システムのイメージをビルドするためのスクリプト集です。live-build の背景となる考え方は、設定ディレクトリを使って Live イメージのビルドに関するあらゆる面を完全に自動化、独自化するツール集ということです。

コマンドは live-build コマンドの名前です (以下参照)。

More documentation about how to use live-build is available in the individual manpages for each helper and in the manual at <https://live-team.pages.debian.net/live-manual/>.

オプション

live-build 共有オプション

以下のコマンドラインオプションは全 live-build プログラムでサポートされています。

ヘルプを表示して終了します。
使用方法を表示して終了します。
バージョン情報を表示して終了します。

live-build 共通オプション

以下のコマンドラインオプションはほとんどの live-build プログラムでサポートされています。各オプションの完全な説明については各プログラムの man ページを見てください。

ブレークポイントをたどります。
enable color use in messages.
デバッグ情報を表示します。
段階ファイルが存在する場合でも強制的にヘルパーを実行します。
disable color use in messages.
出力するメッセージを少なくします。
出力するメッセージを多くします。

We divide live-build into high level ("porcelain") commands, secondary major build stage ("porcelain") commands, and low level ("plumbing") commands.

利用可能な全 live-build コマンドの一覧です。詳しくはそれぞれの man ページを見てください。

高レベルコマンド (PORCELAIN)

高レベルコマンドは主要コマンドといくらかの副次的なユーザ向けユーティリティに分けられています。

主要コマンド

config(1)
creates configuration for live-build
build(1)
executes the build process (by executing all of the secondary level major build stages in sequence)
clean(1)
cleans up system build directories

副次的なコマンド

lb(1)
generic live-build script execution wrapper

The following are the commands that execute each major stage of the build process, in their necessary order of execution. Normally a user might just execute the higher level lb build(1) command rather than use these individually.

bootstrap(1)
executes the first build stage, creating (bootstraping) a basic Debian root filesystem
chroot(1)
executes the second build stage, building the live OS filesystem
installer(1)
executes the third build stage, obtaining installer components (optional)
binary(1)
executes the fourth build stage, generating the binary (live) image
source(1)
executes the fifth build stage, generating a corresponding source image (optional)

LOW-LEVEL COMMANDS (PLUMBING) - BUILD STAGE COMPONENTS

The actual work of live-build is implemented in the low-level commands, called plumbing. They are not supposed to be used by end users, who should stick with porcelains as they ensure that all the different plumbing commands are executed in the right order. However, if you intend to reuse live-build commands in your own scripts, then the plumbings might be of interest for you.

この低レベルコマンドへのインターフェイス (オプション群やセマンティクス) は高レベルの主要コマンドよりもはるかに安定していることが求められることに注意してください。それに対して高レベルの主要コマンドへのインターフェイスは、エンドユーザの使い勝手改善のために変更される対象となります。

bootstrap_archives(1)
applies apt archive configuration
bootstrap_cache(1)
in save mode, saves to cache a copy of the generated bootstrap directory, and in restore mode, restores from cache a previously generated copy
bootstrap_debootstrap(1)
creates (bootstraps) a basic Debian root filesystem using debootstrap(8)

Note: The following chroot_ prefixed commands are used in building the live OS filesystem. Another set of similarly prefixed files are listed separately (see further down).

chroot_cache(1)
in save mode, saves to cache a copy of the chroot directory, and in restore mode, restores from cache a previously generated copy
chroot_firmware(1)
compiles a list of firmware packages to be installed in the live OS root filesystem
chroot_hacks(1)
executes local hacks against the live OS root filesystem, if any are provided
chroot_hooks(1)
executes local hooks against the live OS root filesystem, if any are provided
chroot_includes(1)
copies a set of local files from the config directory into the live OS root filesystem, if any are provided
chroot_install-packages(1)
installs into the live OS root filesystem any packages listed in local package lists
chroot_interactive(1)
pauses the build process and starts an interactive shell from the live OS root filesystem, providing an oportunity for manual modifications or testing; note that this is (currently) usually executed with several chroot prep modifications applied (see description of these further down)
chroot_linux-image(1)
compiles a list of kernel images to be installed in the live OS root filesystem
chroot_package-lists(1)
compiles a list of packages provided in the user´ local config to be installed in the live OS root filesystem
chroot_preseed(1)
installs pre-configured answers to certain install prompts into the live OS root filesystem

installer_debian-installer(1)
obtains and sets up Debian installer (d-i) components
installer_preseed(1)
installs pre-configured answers to certain install prompts

binary_checksums(1)
creates checksums (md5, sha1, and/or sha256) for live image content
binary_chroot(1)
duplicates the chroot directory, to place a copy of what would be the completed live OS root filesystem to one side, allowing the original to continue to be used in executing certain parts of the remainder of the build process
binary_disk(1)
creates disk information files to be added to live image
binary_grub_cfg(1)
creates the config for grub-pc and grub-efi, and also enables loopback support (which depends upon it) in the live image
binary_grub-efi(1)
installs grub-efi (grub2 for EFI) into live image to provide image boot capability. It relies upon lb binary_grub_cfg to create the config.
binary_grub-legacy(1)
installs grub into live image to provide image boot capability
binary_grub-pc(1)
installs grub-pc (grub2 for BIOS) into live image to provide image boot capability. It relies upon lb binary_grub_cfg to create the config.
binary_hdd(1)
compiles the final live image into an HDD image file
binary_hooks(1)
executes local hooks against the live image, if any are provided
binary_includes(1)
copies a set of local files from the config directory into the live image, if any are provided
binary_iso(1)
compiles the final live image into an ISO file
binary_linux-image(1)
copies the linux-image into the live image
binary_loadlin(1)
bundles a copy of loadlin into the live image
binary_manifest(1)
creates manifest of packages installed into live OS filesystem, and list of packages to be excluded by a persistence mechanism installing the live OS to disk
binary_memtest(1)
bundles a copy of memtest into the live image
binary_netboot(1)
compiles the final live image into a netboot tar archive
binary_onie(1)
installs onie into the live image
binary_package-lists(1)
processes local lists of packages to obtain and bundle into image (from which they could later be installed if not already)
binary_rootfs(1)
wraps up the completed live OS root filesystem into a virtual file system image
binary_syslinux(1)
installs syslinux into live image to provide image boot capability
binary_tar(1)
compiles the final live image into a tar archive
binary_win32-loader(1)
bundles a copy of win32-loader into the live image and creates an autorun.inf file
binary_zsync(1)
builds zsync control files

source_checksums(1)
creates checksums (md5, sha1, and/or sha256) for source image content
source_debian(1)
downloads source packages for bundling into source image
source_disk(1)
creates disk information files to be added to source image
source_hdd(1)
compiles the final source image into an HDD image file
source_hooks(1)
executes local hooks against the source image, if any are provided
source_iso(1)
compiles the final source image into an ISO file
source_live(1)
copies live-build config into source
source_tar(1)
compiles the final source image into a tar archive

LOW-LEVEL COMMANDS (PLUMBING) - CHROOT PREP COMPONENTS

The notes above under the section regarding build-stage specific low-level plumbing commands also apply here.

The following chroot_ prefixed commands are used throughout the various primary stages of the build process to apply and remove modifications to a chroot root filesystem. Generally these are used to apply modification that setup the chroot for use (execution of programs within it) during the build process, and later to remove those modification, unmounting things that were mounted, and making the chroot suitable for use as the root filesystem of the live OS to be bundled into the live image.

Note that the lb chroot_prep(1) command can be used to run these components in bulk.

chroot_prep(1)
a helper to run the below components in bulk. The first parameter it takes is the execution mode - install or remove - to pass along. The second parameter is the set of helpers to run (they can be space or comma separated; remember to quote if space separated). Following this one or more of the special parameters 'mode-archives-chroot', 'mode-archives-binary', 'mode-archives-source' and 'mode-apt-install-binary' can optionally be used, to select the 'pass' parameter for lb chroot_archives(1) in the case of the first three (required if 'archives' is one of the helpers to be run), and to run lb chroot_apt(1) in 'install-binary' mode in the last case. Any remaining parameters (i.e. options like --force) are passed along to all scripts run. The second parameter can be simply 'all' in which case a default set of all components are used, or 'all-except-archives' which differs in skipping lb chroot_archives(1). Components can be specified without their filename 'chroot_' prefix for brevity. In remove mode the list of components are run in reverse order, so no need to provide them in reverse order yourself.
chroot_apt(1)
manages apt configuration; in apply mode it applies configuration for use during build process, and in remove mode removes that configuration
chroot_archives(1)
manages apt archive source lists; in apply mode it applies source list configurations suitable for use of the chroot in the build process, and in remove mode replaces that with a configuration suitable for the final live OS
chroot_debianchroot(1)
manages a /etc/debian_chroot file
chroot_devpts(1)
manages mounting of /dev/pts
chroot_dpkg(1)
manages dpkg; in apply mode disabling things like the start-stop-daemon, and in remove mode enabling them again
chroot_hostname(1)
manages the hostname configuration
chroot_hosts(1)
manages the /etc/hosts file
chroot_proc(1)
manages mounting of /proc
chroot_resolv(1)
manages configuration of the /etc/resolv.conf file
chroot_selinuxfs(1)
manages mounting of /sys/fs/selinux
chroot_sysfs(1)
manages mounting of /sys
chroot_sysv-rc(1)
manages the /usr/sbin/policy-rc.d file
chroot_tmpfs(1)
manages configuration of dpkg to use a tmpfs filesystem

設定ファイル

Many live-build commands make use of files in the config/ directory to control what they do. Besides the common config/common, which is used by all live-build commands, some additional files can be used to configure the behavior of specific live-build commands. These files are typically named config/stage (where "stage" of course, is replaced with the name of the stage that they belong to).

live-build は実行中のシェルに存在する環境変数を尊重することに注意してください。変数が設定ファイルから読み取れる場合にはそれが環境変数より優先され、コマンドラインオプションで指定された場合にはそれが設定ファイルの値より優先されます。ある変数が見つからない、つまり値がセットされていない場合は live-build が自動的にデフォルト値をセットします。

In some rare cases, you may want to have different versions of these files for different architectures or distributions. If files named config/stage.arch and config/stage.dist exist, where "arch" is the same as the output of "dpkg --print-architecture" and "dist" is the same as the codename of the target distribution, then they will be used in preference to other, more general files.

設定ファイルは全て、live-build プログラムにより作成されたシェルスクリプトです。それはつまり、通常のシェル構文に従う必要があるということです。また、設定ファイルにはコメントを残しておくこともできます。「#」で始まる行は無視されます。

ファイル

/etc/live/build.conf
/etc/live/build/*

関連項目

live-boot(7)

live-config(7)

このプログラムは live-build の一部です。

ホームページ

More information about live-build and the Debian Live project can be found on the homepage at <https://wiki.debian.org/DebianLive>.

バグ

Bugs can be reported by submitting a bug report for the live-build package in the Bug Tracking System at <http://bugs.debian.org/> or by writing a mail to the Debian Live mailing list at <debian-live@lists.debian.org>.

作者

live-build was originally written by Daniel Baumann <mail@daniel-baumann.ch>. Since 2016 development has been continued by the Debian Live team.

2021-04-07 1:20210407