aboutsummaryrefslogtreecommitdiffstats
path: root/.extras/image-builder/README
diff options
context:
space:
mode:
Diffstat (limited to '.extras/image-builder/README')
-rw-r--r--.extras/image-builder/README58
1 files changed, 58 insertions, 0 deletions
diff --git a/.extras/image-builder/README b/.extras/image-builder/README
new file mode 100644
index 0000000..4802ba6
--- /dev/null
+++ b/.extras/image-builder/README
@@ -0,0 +1,58 @@
+sbo-testbuild image builder
+===========================
+
+Builds the docker images that .extras/test-build consumes:
+ docker.noland.dnx:5000/sbo-testbuild:current
+ docker.noland.dnx:5000/sbo-testbuild:15.0
+
+Three scripts, chained (see .extras/docs/specs/2026-07-13-image-builder-design.md):
+ bootstrap.sh sbo-base:{ver} FROM scratch, base pkgs from NAS
+ build-full-image.sh sbo-full:{ver} FROM base, all series
+ build-sbo-testbuild.sh sbo-testbuild:{ver} FROM full, + sbopkg + tools
+
+All settings live in ./config.
+
+VM setup (docker.noland.dnx, Slackware x86_64, 4 vCPU / 4 GB / 80 GB)
+--------------------------------------------------------------------
+1. Install docker; enable the daemon.
+
+2. NFS-mount the two NAS trees read-only, named to match:
+ /mnt/nas/slackware64-current -> -current mirror tree
+ /mnt/nas/slackware64-15.0 -> 15.0 mirror tree
+ Each is a full mirror (PACKAGES.TXT, ChangeLog.txt, slackware64/, patches/,
+ extra/). Root must be able to read them (bootstrap runs installpkg as root).
+
+3. Run a LAN registry:
+ docker run -d --restart=always -p 5000:5000 \
+ -v /opt/registry/data:/var/lib/registry --name registry registry:2
+
+4. Mark the registry insecure (plain HTTP) on the VM AND every pulling client
+ (this dev box, the buildsystem VM). In /etc/docker/daemon.json:
+ { "insecure-registries": ["docker.noland.dnx:5000"] }
+ then restart docker.
+
+5. Drop the two prebuilt packages (built once, re-drop on upstream bumps):
+ /opt/sbo-testbuild/pkgs/sbopkg-*.txz
+ /opt/sbo-testbuild/pkgs/sbo-maintainer-tools-*.txz
+
+6. Install the nightly cron (root):
+ 0 4 * * * /path/to/.extras/image-builder/bootstrap.sh >> /var/log/sbo-testbuild.log 2>&1
+ 15 4 * * * /path/to/.extras/image-builder/build-full-image.sh >> /var/log/sbo-testbuild.log 2>&1
+ 30 4 * * * /path/to/.extras/image-builder/build-sbo-testbuild.sh >> /var/log/sbo-testbuild.log 2>&1
+
+7. Ensure docker.noland.dnx resolves on the LAN (static IP or DNS).
+
+Manual first run
+----------------
+ ./bootstrap.sh --version current --force
+ ./build-full-image.sh --version current --force
+ ./build-sbo-testbuild.sh --version current --force
+Then confirm:
+ docker pull docker.noland.dnx:5000/sbo-testbuild:current
+ docker run --rm docker.noland.dnx:5000/sbo-testbuild:current sbopkg -V
+
+Flags: --force (rebuild unconditionally), --version <current|15.0> (one variant).
+
+Tests
+-----
+ bash test-image-builder.sh # pure-logic self-check, no docker