This repository provides automated builds of up-to-date Docker packages (docker, dockerd, containerd, runc) for OpenWrt routers using GitHub Actions and the official OpenWrt SDK Docker image.
The official OpenWrt Docker packages are often outdated and lag behind the latest Docker releases. This repository automatically:
- ✅ Uses the official OpenWrt SDK Docker image (
openwrt/sdk) for reproducible builds - ✅ Fetches the latest Docker, Dockerd, and Containerd versions from their respective GitHub repositories
- ✅ Builds packages for your specific OpenWrt architecture
- ✅ Publishes pre-compiled packages as GitHub releases
- ✅ Runs weekly to ensure you always have access to the newest versions
Note: This repository only builds packages for Raspberry Pi 5 (bcm27xx/bcm2712) by default. If you need packages for a different architecture, skip to Option 2 below.
- Visit the Releases page
- Download the package files for Raspberry Pi 5:
- For OpenWrt 25.12+ (snapshots): Download
.apkfiles (uses APK package manager) - For OpenWrt 24.10 and earlier: Download
.ipkfiles (uses OPKG package manager)
- For OpenWrt 25.12+ (snapshots): Download
- Transfer them to your OpenWrt router
- Install using the appropriate package manager:
- APK:
apk add <package>.apk - OPKG:
opkg install <package>.ipk
- APK:
This is useful if you need packages for a different architecture or want to customize the build.
- Click the Fork button at the top of this repository
- This creates your own copy where you can trigger builds
- Go to your forked repository
- Click on the Actions tab
- Click "I understand my workflows, enable them" if prompted
You can trigger builds in two ways:
Manual Trigger:
- Go to Actions → Build Latest Docker for OpenWrt
- Click Run workflow
- Configure your build:
- OpenWrt Version: Enter
stable(for latest stable),snapshotor a specific version like24.10.0 - Target Architecture: Enter your router's target (e.g.,
bcm27xx/bcm2712,x86/64,ramips/mt7621)
- OpenWrt Version: Enter
- Click Run workflow
Automatic Weekly Builds:
The workflow automatically runs every Sunday at midnight (UTC) with default settings:
- OpenWrt Version:
stable(latest stable release) - Target:
bcm27xx/bcm2712(Raspberry Pi 5)
The weekly build workflow tracks deployments in GitHub, so you can view build history and status under the Environments section of your repository.
You can edit .github/workflows/weekly-build.yml to change the default architecture or schedule.
- Wait for the workflow to complete (typically 20-40 minutes)
- Go to Releases in your forked repository
- Download the
.ipkfiles from the latest release - Optionally, check the Environments tab to see deployment history and status
This repository can build Docker packages for any architecture supported by OpenWrt. Common targets include:
| Router/Device | Target Architecture | Example |
|---|---|---|
| Raspberry Pi 5 | bcm27xx/bcm2712 |
Default |
| Raspberry Pi 4 | bcm27xx/bcm2711 |
|
| Raspberry Pi 3 | bcm27xx/bcm2710 |
|
| x86/64 (VMs) | x86/64 |
VMware, VirtualBox |
| MediaTek MT7621 | ramips/mt7621 |
Many routers |
| Qualcomm IPQ40xx | ipq40xx/generic |
|
| Qualcomm IPQ806x | ipq806x/generic |
- SSH into your OpenWrt router
- Run:
cat /etc/openwrt_release | grep TARGET - The output shows your target architecture, for example:
DISTRIB_TARGET='bcm27xx/bcm2712' - Use this value when triggering a manual build
You can build packages for:
stable: Automatically resolves to the latest stable release (e.g.,24.10.5)snapshot: The latest development version (25.12+, uses APK package manager)- Stable releases: e.g.,
24.10.0,23.05.3,23.05.2, etc. (use OPKG package manager)
Important: OpenWrt 25.12 and newer snapshots use the APK (Alpine Package Keeper) package manager instead of OPKG. This repository automatically detects and builds the appropriate package format (.apk or .ipk) based on the version you select.
To find available versions:
- Visit https://downloads.openwrt.org/releases/
- Use the version number (e.g.,
24.10.0) when triggering builds
-
Transfer packages to your router:
scp *.ipk root@192.168.1.1:/tmp/ -
SSH into your router:
ssh root@192.168.1.1
-
Install the packages:
cd /tmp opkg update opkg install containerd*.ipk opkg install runc*.ipk opkg install dockerd*.ipk opkg install docker*.ipk
-
Start Docker:
/etc/init.d/dockerd start /etc/init.d/dockerd enable -
Verify installation:
docker version docker run hello-world
-
Transfer packages to your router:
scp *.apk root@192.168.1.1:/tmp/ -
SSH into your router:
ssh root@192.168.1.1
-
Install the packages:
cd /tmp apk add containerd*.apk apk add runc*.apk apk add dockerd*.apk apk add docker*.apk
-
Start Docker:
/etc/init.d/dockerd start /etc/init.d/dockerd enable -
Verify installation:
docker version docker run hello-world
The workflow builds the following packages:
- docker - Docker CLI client
- dockerd - Docker daemon (engine)
- containerd - Container runtime
- runc - Low-level container runtime
- docker-compose - Docker Compose
All versions are automatically fetched from the latest GitHub releases of:
- moby/moby (Docker engine)
- docker/cli (Docker CLI)
- containerd/containerd (Containerd)
- opencontainers/runc (Runc)
- docker/compose (Docker Compose)
This repository uses the official OpenWrt SDK Docker image (openwrt/sdk) following the standard SDK workflow:
docker run --rm -v "$(pwd)"/bin/:/builder/bin openwrt/sdk
# inside the Docker container
[ ! -d ./scripts ] && ./setup.sh
./scripts/feeds update packages
make defconfig
./scripts/feeds install <package>
make package/<package>/{clean,compile} -j$(nproc)The only addition is scripts/update_versions.sh which fetches the latest Docker, Containerd, and Runc versions from GitHub and patches the OpenWrt package Makefiles before compilation.
- Verify your architecture is correct by checking
/etc/openwrt_releaseon your router - Some older OpenWrt versions may not be compatible with the latest Docker versions
- Check the Actions logs for specific error messages
- Ensure you have enough storage space (Docker requires significant space)
- Some architectures may have missing dependencies - install them with
opkg install - Check that your OpenWrt version matches the packages you downloaded
If you encounter errors like iptables: can't initialize iptables table 'raw': Table does not exist, this indicates the kmod-ipt-raw kernel module is missing.
What causes this error?
Docker networking requires the iptables raw table for advanced packet filtering. This table is provided by the kmod-ipt-raw kernel module, which is not always included by default in OpenWrt.
How this repository solves it:
This repository automatically includes kmod-ipt-raw as a dependency in all built dockerd packages. The build script (scripts/update_versions.sh) intelligently patches the dockerd Makefile during compilation to add this dependency, regardless of the Makefile format.
Solutions:
- If using pre-built packages from Releases: The dependency is already included. Install all packages with your package manager (APK or OPKG will automatically install
kmod-ipt-rawalong with dockerd) - If the error persists after installation: Manually install the module:
opkg install kmod-ipt-raworapk add kmod-ipt-raw, then restart dockerd:/etc/init.d/dockerd restart - For custom builds: The
scripts/update_versions.shscript automatically handles this during the build process
This repository contains build automation scripts. The actual Docker, Dockerd, and Containerd packages are governed by their respective licenses.
Contributions are welcome! Feel free to:
- Report issues with specific architectures or versions
- Suggest improvements to the build workflow
- Submit pull requests