|
| 1 | +# Overview |
| 2 | + |
| 3 | +> [!NOTE] |
| 4 | +> This repo & docs is very much in flux. |
| 5 | +> For project purpose see [Server Bootstrap Project Concise project summary & deliverables](https://docs.google.com/document/d/15YR0hAkHfq8g_2rFzpKjpKf1mytyygREyR7a1ZWfzhE/edit?usp=sharing) |
| 6 | +> For background reading also see [https://github.com/KarmaComputing/server-bootstrap](https://github.com/KarmaComputing/server-bootstrap) |
| 7 | +
|
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | +## Table of contents |
| 12 | + |
| 13 | +- [Alpine Mirroring](./deploy/alpine-mirror/README.md) |
| 14 | + |
| 15 | + |
| 16 | + |
| 17 | +## Run for debugging |
| 18 | + |
| 19 | +- In `internal/runner` |
| 20 | + |
| 21 | + ```sh |
| 22 | + URL=https://192.168.0.230 USERNAME=Administrator PASSWORD=A0F7HKUU VALIDCERT=false WIPEINTERVAL=300 go run . |
| 23 | + ``` |
| 24 | + |
| 25 | +## Full deploy |
| 26 | + |
| 27 | +1. Build |
| 28 | + - Building ipxe.iso image |
| 29 | + - Use new/existing iPXE config file in `deploy/build/ipxe/scripts` |
| 30 | + - Input its name as FILE variable in `deploy/scripts/build-ipxe-iso.sh` |
| 31 | + - Run `deploy/scripts/build-ipxe-iso.sh` |
| 32 | + - `ipxe.iso` is placed in `deploy/serve/www` |
| 33 | + - Building alpine-netboot image |
| 34 | + - Run `deploy/scripts/build-alpine.sh` |
| 35 | + - Files are placed in `deploy/serve/www/iso` |
| 36 | + - SSH keys |
| 37 | + - An SSH keypair is automatically generated upon building an `ipxe.iso` image with the above command |
| 38 | + - The **private** key is placed at `deploy/ssh/key` |
| 39 | + - The **public** key is placed at `deploy/serve/www/ssh/key.pub` |
| 40 | + - Up **re**building the `ipxe.iso`, the script will prompt to replace these keys or not |
| 41 | + |
| 42 | +2. Run stack |
| 43 | + - Ensure the files are correctly placed from step 1 |
| 44 | + - `podman compose up -d` in repository root |
| 45 | + |
| 46 | +3. !! VM FOR TESTING !! |
| 47 | + - Ensure `qemu` is installed and runnable |
| 48 | + - Ensure web server is accessible at whatever address is defined in the iPXE boot script |
| 49 | + - `qemu-system-x86_64 -cdrom <ipxe.iso> -net nic -net user,hostfwd=tcp::2223-:22 -m 3072 -smp $(nproc)` |
| 50 | + - VM can be accessed over SSH at `localhost:2223` |
0 commit comments