|
|
@@ -246,3 +246,76 @@ lua5.1 src/balancerlite/main.lua \
|
|
|
- Real (non-dry-run) end-to-end actuator test (needs `ip`/`wg` on a
|
|
|
real interface).
|
|
|
- Optional: procd SIGHUP hot-reload; signed-webhook outbox unit tests.
|
|
|
+
|
|
|
+## 2026-09-05 OpenWrt 23.05 testbed built + full suite green
|
|
|
+
|
|
|
+### What
|
|
|
+Built a second testbed on **OpenWrt 23.05.6 x86_64** (the user's follow-up
|
|
|
+request after the 19.07 pass). The 19.07 container was shut down
|
|
|
+(`stop.sh --rm`) first.
|
|
|
+
|
|
|
+Key finding: the "23.05 ships Lua 5.4" hypothesis is **false** —
|
|
|
+OpenWrt 23.05's base `lua` package is **Lua 5.1.5** (same major as
|
|
|
+19.07), so **no 5.4-compat pass is needed**. The existing 5.1-targeted
|
|
|
+code runs unmodified.
|
|
|
+
|
|
|
+### How the 23.05 image is built
|
|
|
+There is **no** `shellspec/openwrt` tag for 23.05 (that repo tops out
|
|
|
+at 19.07.7), and Docker Hub's `openwrt/rootfs` only has 24.10/25.12
|
|
|
+for x86_64. So `testbed/Dockerfile-2305` builds from the **official
|
|
|
+23.05.6 x86_64 rootfs tarball** (downloads.openwrt.org) + four .ipk
|
|
|
+payloads from the 23.05.6 feeds:
|
|
|
+
|
|
|
+- `lua` + `liblua5.1.5` — Lua 5.1.5 interpreter + its shared lib
|
|
|
+- `openssl-util` + `libopenssl3` + `ca-bundle` — `sha256.lua` uses `openssl dgst`
|
|
|
+
|
|
|
+Two build gotchas (both hit): busybox `tar` can't read `.ipk` (ar)
|
|
|
+archives, so .ipk payloads are extracted on the **host** (GNU tar) and
|
|
|
+`COPY`ed; and `lua` alone is not enough — it's a symlink to `lua5.1`
|
|
|
+which needs the separate `liblua5.1.5` .ipk (else `lua -v` dies on
|
|
|
+"Error loading shared library liblua.so.5.1.5").
|
|
|
+
|
|
|
+New files:
|
|
|
+- `testbed/Dockerfile-2305` — scratch build from official rootfs + ipk payloads
|
|
|
+- `testbed/download-2305.sh` — idempotent fetcher for rootfs + 5 .ipks + pre-extract
|
|
|
+- `testbed/README.md` — how to build/run both 19.07 & 23.05 testbeds + docker-cp gotcha
|
|
|
+- `testbed/.gitignore` — ignores the large fetched artifacts (rootfs/, ipks/, ipk-extract/)
|
|
|
+
|
|
|
+### Test Results (OpenWrt 23.05.6 testbed, Lua 5.1.5)
|
|
|
+```
|
|
|
+ALL 7 SUITES PASS
|
|
|
+ sha256 → 3/3 vectors PASS (openssl dgst present)
|
|
|
+ state → PASS
|
|
|
+ routing → 32/32
|
|
|
+ wg → 35/35
|
|
|
+ ctl → 42/42
|
|
|
+ smoke → 21/21 (incl. [1b] wan-section-load checks)
|
|
|
+ probes_config → 21/21
|
|
|
+daemon --dry-run → "(DRY RUN)" banner, routing cmds printed,
|
|
|
+ "exited after 1 cycles", rc=0, no crash, no
|
|
|
+ "unsafe iface/gw" warnings
|
|
|
+```
|
|
|
+
|
|
|
+### Verify commands
|
|
|
+```sh
|
|
|
+cd /root/.openclaw/workspace/balancer-lite-lua/testbed
|
|
|
+./download-2305.sh
|
|
|
+docker build -f Dockerfile-2305 -t openwrt-testbed-2305:latest .
|
|
|
+S=skills/openwrt-testbed/scripts
|
|
|
+OPENWRT_TESTBED_NAME=openwrt-testbed-2305 OPENWRT_TESTBED_IMAGE=openwrt-testbed-2305:latest $S/start.sh
|
|
|
+# then run testbed-runner.lua inside (see testbed/README.md)
|
|
|
+```
|
|
|
+
|
|
|
+### Notes
|
|
|
+- 23.05 testbed container `openwrt-testbed-2305` left **running** (image
|
|
|
+ cached, ready to reuse). Image is ~small (scratch + 2.7MB rootfs +
|
|
|
+ ipk payloads).
|
|
|
+- 19.07 container was `stop.sh --rm`'d (gone). 23.05 is the active testbed.
|
|
|
+- Hypothesis log: 23.05 → Lua **5.1.5** (not 5.4). If a future OpenWrt
|
|
|
+ bumps base lua to 5.4, revisit: `goto`, `#` on nil, integer-division
|
|
|
+ (`//` vs `/`) semantics. Not needed now.
|
|
|
+
|
|
|
+### Open loops
|
|
|
+- Real (non-dry-run) end-to-end actuator test (needs `ip`/`wg` on a live
|
|
|
+ interface — neither testbed has `wg` installed).
|
|
|
+- Optional: procd SIGHUP hot-reload; signed-webhook outbox unit tests.
|