Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 5 additions & 18 deletions Dockerfile.tools
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# the base image's user, entrypoint, command, working directory, environment,
# healthcheck, and controlled package versions. It ships no compiler.

ARG BASE_IMAGE=docker.io/derekhsu/openshell-openclaw@sha256:e654a0695522944ec43c7eeabb6aca9472f385c117a206e5000f8a61b1b96056
ARG BASE_IMAGE=docker.io/derekhsu/openshell-openclaw@sha256:e09ef7b05b3663affab649b0403c09d01ad1cf9858ffc3ede01399ec89b5e9df

# Downloaded single-file tools, verified by checksum. The final stage
# installs the file for its own architecture through a bind mount, so the
Expand All @@ -35,18 +35,6 @@ ADD --checksum=sha256:5c5ba2724c162f82d0a0c71b6c03224ed44f8bef7b14ace5da0635d3af
ADD --checksum=sha256:1dc21c3dd6d948929e22e5cae49b9d0b3b30ff88fafd4493fd4460c6252e9d90 \
https://github.com/pimalaya/himalaya/releases/download/v2.2.1/himalaya.aarch64-linux.tgz /himalaya-arm64.tgz

# libc6-dev must match the base image's libc6 exactly. Debian has replaced
# 2.41-12+deb13u4 in the archive, so fetch it from the snapshot archive for the
# perl-modules stage. Update these with the base image's libc6 version.
ADD --checksum=sha256:1fda734dabcd80b77266a09ab62b0f1e3e16d8091db62899890b2200745632a2 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc6-dev_2.41-12%2Bdeb13u4_amd64.deb /libc6-dev-amd64.deb
ADD --checksum=sha256:71e373cb5e9da975b02fb4af555929cb1977560e2dd8245de4eb8a7b03677a08 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc6-dev_2.41-12%2Bdeb13u4_arm64.deb /libc6-dev-arm64.deb
ADD --checksum=sha256:2c21175d6a8283ed566d154c0c0bc06f60836e53b0b9e1f74c14eac586b68c24 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc-dev-bin_2.41-12%2Bdeb13u4_amd64.deb /libc-dev-bin-amd64.deb
ADD --checksum=sha256:cd4b3bdf404a01792003f4ca400bc602252ab24e0a8c53e45d474d1818dc02e3 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc-dev-bin_2.41-12%2Bdeb13u4_arm64.deb /libc-dev-bin-arm64.deb

# The yq 4.54.1 release binaries use Go 1.27.1 and golang.org/x/net 0.59.0,
# which have HIGH vulnerabilities with available fixes. Build the same yq version with a
# patched Go toolchain and x/net. Go verifies module hashes with sumdb.
Expand All @@ -68,16 +56,15 @@ FROM ${BASE_IMAGE} AS perl-modules
USER root
ADD --checksum=sha256:abded5f4fdd9338e89fd2f1d8271c44989dae5bf50aece41b6179d8e230704f8 \
https://cpan.metacpan.org/authors/id/K/KU/KUBOTA/Text-CharWidth-0.04.tar.gz /tmp/Text-CharWidth-0.04.tar.gz
# libc6-dev must match the base image's libc6, which is held; apt fails
# if Debian moves past it.
# hadolint ignore=DL3003,DL3008
RUN --mount=type=bind,from=downloads,target=/downloads \
set -eu; \
RUN set -eu; \
while IFS='=' read -r pkg _; do \
[ "$pkg" = architecture ] || apt-mark hold "$pkg" >/dev/null; \
done </usr/local/share/nemoclaw/security-packages.txt; \
apt-get update; \
arch="$(dpkg --print-architecture)"; \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends gcc make dpkg-dev \
"/downloads/libc6-dev-$arch.deb" "/downloads/libc-dev-bin-$arch.deb"; \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends gcc make libc6-dev dpkg-dev; \
mkdir -p /tmp/charwidth /tmp/stage/DEBIAN /out; \
tar -xzf /tmp/Text-CharWidth-0.04.tar.gz --strip-components=1 -C /tmp/charwidth; \
cd /tmp/charwidth; \
Expand Down
23 changes: 5 additions & 18 deletions agents/hermes-01x/Dockerfile.tools
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

# Tag and index digest of the published Hermes image. The release tag of this
# image is <tag>-tools.<n>.
ARG BASE_IMAGE=docker.io/derekhsu/openshell-hermes:openshell01x-hermes-0.21.3-2026.11.13@sha256:1b0f2030fec36118c9124c0f28a5e435f61bfb4f502f39e942e365873e8c8265
ARG BASE_IMAGE=docker.io/derekhsu/openshell-hermes:openshell01x-hermes-0.21.3-2026.11.25@sha256:89aad1dc08c0c8d7fafc49089f7351b44ed4dec6b5027df6b8d8b193af04a577

# Downloaded single-file tools, verified by checksum. The final stage
# installs the file for its own architecture through a bind mount, so the
Expand All @@ -50,18 +50,6 @@ ADD --checksum=sha256:5c5ba2724c162f82d0a0c71b6c03224ed44f8bef7b14ace5da0635d3af
ADD --checksum=sha256:1dc21c3dd6d948929e22e5cae49b9d0b3b30ff88fafd4493fd4460c6252e9d90 \
https://github.com/pimalaya/himalaya/releases/download/v2.2.1/himalaya.aarch64-linux.tgz /himalaya-arm64.tgz

# libc6-dev must match the base image's libc6 exactly. Debian has replaced
# 2.41-12+deb13u4 in the archive, so fetch it from the snapshot archive for the
# perl-modules stage. Update these with the base image's libc6 version.
ADD --checksum=sha256:1fda734dabcd80b77266a09ab62b0f1e3e16d8091db62899890b2200745632a2 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc6-dev_2.41-12%2Bdeb13u4_amd64.deb /libc6-dev-amd64.deb
ADD --checksum=sha256:71e373cb5e9da975b02fb4af555929cb1977560e2dd8245de4eb8a7b03677a08 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc6-dev_2.41-12%2Bdeb13u4_arm64.deb /libc6-dev-arm64.deb
ADD --checksum=sha256:2c21175d6a8283ed566d154c0c0bc06f60836e53b0b9e1f74c14eac586b68c24 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc-dev-bin_2.41-12%2Bdeb13u4_amd64.deb /libc-dev-bin-amd64.deb
ADD --checksum=sha256:cd4b3bdf404a01792003f4ca400bc602252ab24e0a8c53e45d474d1818dc02e3 \
https://snapshot.debian.org/archive/debian/20260711T202405Z/pool/main/g/glibc/libc-dev-bin_2.41-12%2Bdeb13u4_arm64.deb /libc-dev-bin-arm64.deb

# The yq 4.54.1 release binaries use Go 1.27.1 and golang.org/x/net 0.59.0,
# which have HIGH vulnerabilities with available fixes. Build the same yq version with a
# patched Go toolchain and x/net. Go verifies module hashes with sumdb.
Expand All @@ -83,16 +71,15 @@ FROM ${BASE_IMAGE} AS perl-modules
USER root
ADD --checksum=sha256:abded5f4fdd9338e89fd2f1d8271c44989dae5bf50aece41b6179d8e230704f8 \
https://cpan.metacpan.org/authors/id/K/KU/KUBOTA/Text-CharWidth-0.04.tar.gz /tmp/Text-CharWidth-0.04.tar.gz
# libc6-dev must match the base image's libc6, which is held; apt fails
# if Debian moves past it.
# hadolint ignore=DL3003,DL3008
RUN --mount=type=bind,from=downloads,target=/downloads \
set -eu; \
RUN set -eu; \
while IFS='=' read -r pkg _; do \
[ "$pkg" = architecture ] || apt-mark hold "$pkg" >/dev/null; \
done </usr/local/share/nemoclaw/security-packages.txt; \
apt-get update; \
arch="$(dpkg --print-architecture)"; \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends gcc make dpkg-dev \
"/downloads/libc6-dev-$arch.deb" "/downloads/libc-dev-bin-$arch.deb"; \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends gcc make libc6-dev dpkg-dev; \
mkdir -p /tmp/charwidth /tmp/stage/DEBIAN /out; \
tar -xzf /tmp/Text-CharWidth-0.04.tar.gz --strip-components=1 -C /tmp/charwidth; \
cd /tmp/charwidth; \
Expand Down
9 changes: 4 additions & 5 deletions docs/modification/2026-10-31-openclaw-tools-image.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ agent 在 sandbox 內處理這些工作時,不需要在執行期間下載套件
| 額外工具 | 無 | 第 3 節列出的套件 |
| 映像大小 | 約 2.3 GB | 約 5.6–5.7 GB(`2026.9.2-tools.3`:amd64 增加 3.37 GB,arm64 增加 3.27 GB) |

目前的 base 是 `docker.io/derekhsu/openshell-openclaw:2026.9.2-r4`,
目前的 base 是 `docker.io/derekhsu/openshell-openclaw:2026.9.2-r5`,
index digest 為
`sha256:e654a0695522944ec43c7eeabb6aca9472f385c117a206e5000f8a61b1b96056`。
`sha256:e09ef7b05b3663affab649b0403c09d01ad1cf9858ffc3ede01399ec89b5e9df`。
`Dockerfile.tools` 以這個 digest 作為預設 `BASE_IMAGE`。
不使用 `2026.9.2` tag,因為它指向較舊的發布產物。

Expand Down Expand Up @@ -83,7 +83,6 @@ Debian 套件在 amd64 與 arm64 上的版本相同。
| yq(Mike Farah) | 4.54.1 | amd64、arm64;以 Go 1.27.4 與 `golang.org/x/net` 0.62.0 從原始碼建置 |
| p5.js(`p5.min.js`) | 1.7.0 | 不分架構 |
| Text-CharWidth 原始碼 | 0.04 | 建置階段重新編譯,見 6.3 節 |
| `libc6-dev`、`libc-dev-bin` | `2.41-12+deb13u4` | amd64、arm64;只用於編譯 Text::CharWidth,見 6.3 節 |
| pnpm | 12.16.1 | 不分架構 |
| Chrome Headless Shell | 156.0.8078.4(Playwright revision 1248) | amd64、arm64 |
| shadcn 元件 | `anthropics/skills` 固定 revision 的 `web-artifacts-builder` | 不分架構;Apache-2.0,授權檔在模板內 |
Expand Down Expand Up @@ -284,8 +283,8 @@ Debian `0.04-11` 沒有原始碼修補,只多了 hardening 旗標、`dh_perl -d`
最終映像只複製編譯好的套件,不含編譯器。

編譯需要 `libc6-dev`,版本必須與 base 映像的 `libc6` 完全相同。
Debian 套件庫現在只提供 `2.41-12+deb13u5`,而 tools 映像使用的已發布 base 映像,`libc6` 仍是 `2.41-12+deb13u4`。
因此這個 stage 從 `snapshot.debian.org` 下載 `2.41-12+deb13u4` 的 `libc6-dev` 與 `libc-dev-bin`,並以 SHA-256 校驗(#85)。
`2026.9.2-r5`、`2026.9.2-openshell01x-r3` 與 `openshell01x-hermes-0.21.3-2026.11.25` 的 `libc6` 都是 `2.41-12+deb13u5`,與 Debian 套件庫目前的 `libc6-dev` 版本相同,所以這個 stage 直接用 apt 安裝 `libc6-dev`。
之前的 base 映像 `libc6` 是 `2.41-12+deb13u4`,當時改從 `snapshot.debian.org` 下載相同版本的 `libc6-dev`(#85)。

更新 tools 映像使用的 base 映像(Perl 或 `libc6` 版本)時,必須重新檢查這個步驟。

Expand Down
4 changes: 2 additions & 2 deletions docs/modification/2026-11-17-hermes-tools-image.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ agent 在 sandbox 內處理這些工作時,不需要在執行期間下載套件
| 額外工具 | 無 | 與 OpenClaw tools 映像相同,清單見 [OpenClaw tools 映像說明](2026-10-31-openclaw-tools-image.md) 第 3 節 |
| layer 數 | base 的 layer 數 | base 加 8;發布前上限 115 |

目前的 base 是 `docker.io/derekhsu/openshell-hermes:openshell01x-hermes-0.21.3-2026.11.13`,
index digest 為 `sha256:1b0f2030fec36118c9124c0f28a5e435f61bfb4f502f39e942e365873e8c8265`。
目前的 base 是 `docker.io/derekhsu/openshell-hermes:openshell01x-hermes-0.21.3-2026.11.25`,
index digest 為 `sha256:89aad1dc08c0c8d7fafc49089f7351b44ed4dec6b5027df6b8d8b193af04a577`。
`agents/hermes-01x/Dockerfile.tools` 的 `BASE_IMAGE` 同時寫出 tag 與 digest;建置以 digest 為準,tag 用來產生發布 tag。

只提供 OpenShell 0.1.x 版本。OpenShell 0.0.x 的 Hermes 映像(`agents/hermes/`)預定淘汰,不提供 tools 映像。
Expand Down
6 changes: 3 additions & 3 deletions tools/openclaw-tools-image/base-image-openshell01x.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Base image for the OpenShell 0.1.x tools image (<version>-openshell01x-tools.<n>).
# Index digest of docker.io/derekhsu/openshell-openclaw:2026.9.2-openshell01x-r2,
# published by openclaw-sandbox-image run 42639684706 from b2809aa666 (#68 merge).
docker.io/derekhsu/openshell-openclaw@sha256:c2328368e2f3023552d12ad312fb1eb81200787faaf54a8233c55eacb17c7c90
# Index digest of docker.io/derekhsu/openshell-openclaw:2026.9.2-openshell01x-r3,
# published by openclaw-sandbox-image run 45540584883 from 42a4c47a40 (#84 merge).
docker.io/derekhsu/openshell-openclaw@sha256:884879dbc0fa014fa821af6d9d206fff95b87ba661ae6dd6454b06e53d012390
Loading