Add script for usb bootable support
[icn.git] / tools / README.md
1 # Automatic installation script
2
3 `create_usb_bootable.sh` is a script to build an ubuntu ISO
4 with capability of no-attended installation. All the questiones
5 asked during installation are answered by the [preseed file](ubuntu/preseed/ubuntu-server.seed).
6 We copy the icn directory into the target ISO. Before running `create_usb_bootable.sh`
7 , the tools/collect.sh script is called to collect files from
8 the Internet into icn directory. For example, to download deb packages,
9 to pull docker images, etc.
10
11 Each component should has its own collect script. `tools/collect.sh` calls
12 each component collect script one by one. The componnet collect script must follow
13 several rules:
14
15 1. The name of component script should be `collect_xx.sh`
16 1. `set -ex` is needed in component script. So that the parent collect.sh can be awared of
17 the failure of component script.
18 1. The component script should accept one parameter, which is the icn directory. So that
19 the component script knows where to put the collected files.
20 1. Calling the component multiple times must not raise error.
21 1. Component scripts are supposed to run with root permission, we don't have to use `sudo`
22 in the component scripts.