Repository navigation
Description
Split from #7970.
Problem description. The job DevContainer Image of .github/workflows/devcontainer-image.yml averages 417 s over its last 10 successful pull request runs. The limit of AGENTS.md rule 5 is 360 s. The step Build and Push DevContainer Image by Digest takes 175 s to 298 s of each job. The registry cache does not give some layers, and no record names them. Issue #7970 adds the job to devops ci job-time and files one P0 issue for the breach. This issue cuts the build time. It needs #7970 first, so that the mean of the job is measured. The part is deferred because no record names the layers that miss the cache, and only live pull request runs show the new mean. ## Acceptance criteria. 1. The action .github/actions/devcontainer-image/action.yml prints the seconds of the Feature build and of the project build, and the cache hit or miss of each stage. uv run devops ci --check --only actionlint,zizmor passes. 2. One change cuts the build step, and the log of a live run shows a cache hit for the layers that missed the cache before. 3. The mean of the last 10 successful pull request runs of DevContainer Image is at most 360 s, shown by uv run devops ci job-time --repo dan-petty/devops-cli after 10 runs.
Proposed design
Problem statement
The job DevContainer Image averages 417 s over its last 10 successful pull request runs. The limit of AGENTS.md rule 5 is 360 s. The step Build and Push DevContainer Image by Digest takes 175 s to 298 s of each job. No record names the build stage that misses the registry cache, so no change can choose the slow stage now. This change makes the action print the seconds and the cache state of each build stage. A later change cuts the time with those facts.
Acceptance criteria
Requirement: The action prints the seconds of the Feature build and of the project build
The action .github/actions/devcontainer-image/action.yml SHALL print the seconds that the Feature build and the project build take, in the step summary of the job.
Scenario: The static analysis check reads the action
- WHEN A developer runs
uv run devops ci --check --only actionlint,zizmoron the branch - THEN The check passes and reports no finding for
.github/actions/devcontainer-image/action.yml.
Requirement: The action prints the cache hit or miss of each build stage
The action SHALL print the cache hit or miss of each build stage from the --progress=plain log of each docker buildx build call.
Scenario: The static analysis check reads the action
- WHEN A developer runs
uv run devops ci --check --only actionlint,zizmoron the branch - THEN The check passes and reports no finding for
.github/actions/devcontainer-image/action.yml.
Requirement: Pending a person after the merge
The step summary of the next pull request run of DevContainer Image MUST show the seconds and the cache state of each build stage.
Scenario: A person reads the step summary of the next pull request run
- WHEN A person opens the run of
DevContainer Imageof a pull request that changes.devcontainer/** - THEN The step summary shows the seconds and the cache hit or miss of the Feature build and of the project build.
Existing Tool Considered
No alternatives check has run on this issue. The action already uses Docker Buildx, an open, maintained tool under Apache-2.0, and it covers the need: --progress=plain prints each step with its CACHED marker. Buildx lacks a per-stage seconds line, so the action adds shell timestamps around each build and prints one summary line for each stage. The own code costs about 20 shell lines and under one hour of work, and it builds no new tool.
Key questions
- Which tool prints the seconds and the cache state of each build stage?: Docker Buildx with
--progress=plain, plus shell timestamps around each build, printed as one summary line for each stage. (best practice) [sources: .github/actions/devcontainer-image/action.yml]- Chosen: Docker Buildx
--progress=plainwith shell timestamps. The action already runs buildx, and its plain log marks each step asCACHEDor not. - Rejected: A new timing script or action. It builds code that the buildx log and
datealready give. - Rejected: The
--metadata-fileoutput only. It gives the image digest, not the seconds or the cache state of a stage.
- Chosen: Docker Buildx
- Does the pull request job write the registry cache?: No.
.github/workflows/devcontainer-image.ymlgives the actioncache-fromonly and nocache-to, so this job reads the cache and writes none. The action runs three builds: the devtools CLI copy, the Feature build and the project build. Only the last two receivecache-from. [sources: .github/workflows/devcontainer-image.yml, .github/actions/devcontainer-image/action.yml] - Where does the 360 s limit of the job come from?: AGENTS.md rule 5 sets 5 min plus 1 min tolerance, which is 360 s. [sources: AGENTS.md]
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Activity
devops-cli-service commentedon Dec 1, 2026
The job averages 417 s against a 360 s limit, and the project classifies this breach as P0 per AGENTS.md rule 5.Both target the DevContainer Image job, but #4658 changes when it builds while this candidate changes how fast it builds.devops-cli-service commentedon Dec 1, 2026
Next step: the alternatives check records a verdict. See the section Proposed design of the body.
fix(ci): read the DevContainer Image job in job-time (#7997)