Skip to content

Commit

Permalink
Merge pull request #28 from mvallim/readme-environments-definition
Browse files Browse the repository at this point in the history
Update readme to more clearly specify build/live/target systems
  • Loading branch information
mvallim authored Apr 26, 2021
2 parents 91d4706 + 597793c commit a09e123
Showing 1 changed file with 21 additions and 3 deletions.
24 changes: 21 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,15 @@ This procedure shows how to create a **bootable** and **installable** Ubuntu Liv

[![build-focal](https://github.com/mvallim/live-custom-ubuntu-from-scratch/actions/workflows/build-focal.yml/badge.svg)](https://github.com/mvallim/live-custom-ubuntu-from-scratch/actions/workflows/build-focal.yml)

## Terms

* `build system` - the computer environment running the build scripts that generate the ISO.
* `live system` - the computer environment that runs from the live OS, generated by a `build system`. This may also be referred to as the `chroot environment`.
* `target system` - the computer environment that runs after installation has completed from a `live system`.

## Prerequisites (GNU/Linux Debian/Ubuntu)

Install applications we need to build the environment.
Install packages we need in the `build system` required by our scripts.

```shell
sudo apt-get install \
Expand All @@ -35,6 +41,8 @@ mkdir $HOME/live-ubuntu-from-scratch

## Bootstrap and Configure Ubuntu

`debootstrap` is a program for generating OS images. We install it into our `build system` to begin generating our ISO.

* Checkout bootstrap

```shell
Expand Down Expand Up @@ -64,6 +72,8 @@ mkdir $HOME/live-ubuntu-from-scratch

> Reference: https://en.wikipedia.org/wiki/Chroot
From this point we will be configuring the `live system`.

1. **Access chroot environment**

```shell
Expand Down Expand Up @@ -399,6 +409,8 @@ sudo umount $HOME/live-ubuntu-from-scratch/chroot/run
## Create the CD image directory and populate it
We are now back in our `build environment` after setting up our `live system` and will continue creating files necessary to generate the ISO.
1. Access build directory
```shell
Expand Down Expand Up @@ -492,7 +504,8 @@ sudo umount $HOME/live-ubuntu-from-scratch/chroot/run
## Create manifest
In the next steps the creation of the manifest is important because it tells us which version of each package installed in the Live version and which packages will be removed or maintained in the version that will be installed (persisted in the hard drive).
Next we create a file `filesystem.manifest` to specify each package and it's version that is installed on the `live system`. We create another file `filesystem.manifest-desktop` which specifies which files will be installed on the `target system`. Once the Ubiquity installer completes, it will
remove packages specified in `filesystem.manifest` that are *not* listed in `filesystem.manifest-desktop`.
1. Access build directory
Expand Down Expand Up @@ -520,7 +533,7 @@ In the next steps the creation of the manifest is important because it tells us
## Compress the chroot
After everything has been installed and preconfigured in the **chrooted** environment, we need to generate an image of everything that was done by following the next steps.
After everything has been installed and preconfigured in the **chrooted** environment, we need to generate an image of everything that was done by following the next steps in the `build environment`.
1. Access build directory
Expand Down Expand Up @@ -728,6 +741,11 @@ It is simple and easy, using "dd"
```shell
sudo dd if=ubuntu-from-scratch.iso of=<device> status=progress oflag=sync
```
## Summary
This completes the process of creating a live Ubuntu installer from scratch. The generated ISO may be tested in a virtual machine such as `VirtualBox` or written to media and booted from a standard PC.
## Contributing
Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.
Expand Down

0 comments on commit a09e123

Please sign in to comment.