Commit bad0cbb
authored
refactor(box-images)!: adopt v0.1.0 line, relocate under apps/ (#1100)
Points every curated-image reference at the `v0.1.0` tag, gives the box
images a
home matching the rest of the repo, and splits their build from their
release.
## Images
All 53 references move from `20260605-p0-r3` to `v0.1.0` across 41
files. The two
tags are different image lineages, not two versions of one:
| | `20260605-p0-r3` | `v0.1.0` |
| --- | --- | --- |
| daemon | `COPY .../boxlite-daemon` | absent |
| entrypoint | `/boxlite/bin/start-agent-runtime` | none (`node` keeps
stock `docker-entrypoint.sh`) |
| user | root | `boxlite` |
| arch | linux/amd64 only | amd64 **+ arm64** |
Because `v0.1.0` runs unprivileged, the six e2e files that wrote to
`/root` now use
`/workspace` — still on the container rootfs, so `copy_out` sees it, and
owned by
the box user.
## Layout
`images/agent-runtime/` → `apps/box-images/`, joining
`apps/{api,dex,proxy,runner}`,
which already co-locate their Dockerfiles; top-level `images/` is gone.
`scripts/images/build-agent-runtime.sh` → `apps/box-images/build.sh` so
the
Dockerfiles, `VERSION` and builder sit together. "agent-runtime" was
ambiguous next
to `src/guest` (the guest agent) and `apps/runner`.
## Workflows
- **`build-box-images.yml`** (was `publish-boxlite-cloud-images.yml`)
validates only —
both architectures at `PUSH=0`, `contents: read`, no registry login, so
it cannot
write to GHCR.
- **`release-box-images.yml`** is the sole publisher, driven by an
`apps/box-images/vMAJOR.MINOR.PATCH` tag (same convention as the
existing
`sdks/go/v*` tags) and restricted to a release tag or `main`.
Previously any edit under the image directory republished the same tag,
silently
moving the bytes a running box pulls. The release path now rejects a tag
that
disagrees with `VERSION` and refuses to republish an existing version
unless
dispatched with `allow-overwrite`. The existence check reads the
registry API and
branches on HTTP status — only 404 counts as free, so a 5xx or an
expired token
stops the release instead of reading as "not published".
## Verification
- `actionlint` clean on both workflows.
- `build.sh` builds all three flavors from its new location; the
resulting arm64
image IDs match the pre-move builds, and the Dockerfiles are
byte-identical
renames.
- `curated-images.constant.spec.ts` passes 9/9.
- Release-workflow shell was exercised by extracting the `run:` bodies
from the YAML
and driving them directly: version resolution 10/10 (tag/VERSION
disagreement,
missing or wrong tag prefix, prerelease, malformed input) and the
overwrite guard
8/8 across 404 / 200 / 500 / 429 / 401 / token-exchange failure / empty
token /
`allow-overwrite`.
**The e2e suite has not been run against the new images.** The `/root` →
`/workspace`
move is derived from the image config — `images/config.rs:166` reads the
OCI user and
`portal/interfaces/container.rs:131` passes it through — not from an
observed run.
## Notes for review
- This branch is behind `main` and conflicts with `2933c30bd fix(infra):
harden SST
deployments (#1093)` in `apps/infra/.env.example`. Needs a rebase before
merge;
the resolution must keep `v0.1.0`.
- Follow-up, not fixed here: `Record published digests` runs `imagetools
inspect`
under `set -e`, so a flaky inspect reddens the job after a successful
publish. No
silent-damage path — re-running the release hits the overwrite guard.
https://claude.ai/code/session_01T3B2RsTupPrn2gPtHymU5T
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
- **New Features**
- Introduced versioned Box images (`v0.1.0`) for Base, Python, and
Node.js environments.
- Added AMD64 and ARM64 image support.
- Added controlled image publishing with version validation and registry
safeguards.
- **Bug Fixes**
- Updated quickstarts, default configurations, and tests to use
versioned images.
- Standardized container file operations under `/workspace`.
- **Documentation**
- Documented image validation and release workflows, including
non-publishing builds for main-branch changes.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Signed-off-by: dorianzheng <8065637+DorianZheng@users.noreply.github.com>1 parent 2b1945f commit bad0cbb
64 files changed
Lines changed: 627 additions & 247 deletions
File tree
- .github/workflows
- apps
- api/src/box/constants
- box-images
- dashboard/src
- components/Box
- lib/quickstart
- templates
- infra-local/compose
- infra
- scripts
- scripts/test
- e2e
- cases
- lib
- sdks
- c
- go
- node
- stress
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
195 | 195 | | |
196 | 196 | | |
197 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
198 | 218 | | |
199 | 219 | | |
200 | 220 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
12 | | - | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
| 44 | + | |
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| |||
File renamed without changes.
File renamed without changes.
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | | - | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| |||
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | | - | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
| |||
File renamed without changes.
0 commit comments