I had an itch to scratch over the weekend after about the 50th time reminding myself how to use the OpenWRT image builder tool. So I created a little tool to help.
OpenWRT composer takes a YAML manifest which specifies firmware images to build, including what packages to add/remove from the firmware, and how to configure the firmware. The idea is that the firmware image is regarded as immutable; any change in configuration is achieved by producing a new firmware image and loading that onto the device.
Configuration is specified in the YAML manifest, and leverages the NetJSONConfig package to create valid configuration files which are then baked into the firmware image.
Building of the image itself is done inside a container. Currently the Podman container runtime is used, but adding Docker support is on the TODO list, and wouldn't require much work at all.
If you're interested, the code is available here: https://github.com/jonathanunderwood/openwrt-composer
It's early days, the code is rough, but it works. PRs, feature requests, critique are all welcome.