unbridled-41 opened a new issue, #5465:
URL: https://github.com/apache/rocketmq-dashboard/issues/5465

   ### Studio Version
   branch: `rocketmq-studio` @ `6a68042f` (the revision verified; the branch is 
based on it)
   deployed as: deploy.sh / docker build (reproduced with docker 29.1.3)
   
   ### Runtime Environment
   
   Target host of `deploy/deploy.sh`; the reproduction uses the packaged file 
lists and the Dockerfile's context reads.
   
   ### Connected RocketMQ Cluster
   
   Not cluster-specific: the failure happens while building the server image.
   
   ### Describe the Bug
   
   `server/Dockerfile` declares "Build context: REPOSITORY ROOT (not server/)" 
and its first stage reads four paths from that root (`COPY rmqctl/go.mod 
rmqctl/go.sum ./`, `COPY rmqctl/ ./`, `COPY LICENSE NOTICE /src/`). 
`runtime-prebuilt` still builds that stage, because `runtime-base` does `COPY 
--from=rmqctl-build /out/rmqctl ...`. Two of the four were missing from the 
packaged source:
   
   - `deploy/deploy.sh`'s tar shipped `server web deploy rmqctl` but not the 
root `LICENSE`/`NOTICE`, so on a host that does not already have them the build 
dies with `COPY failed: file not found in build context or excluded by 
.dockerignore: stat LICENSE: file does not exist`.
   - the deploy skill's manual path shipped neither `rmqctl` nor 
`LICENSE`/`NOTICE` and built with `... server/` as the context, which cannot 
satisfy `COPY rmqctl/...` at all (`COPY failed: ... stat rmqctl/go.mod: file 
does not exist`).
   
   ### Steps to Reproduce
   
   1. Package the sources with the documented tar list and extract them on a 
clean host (or reproduce the context reads directly against that file list).
   2. Run the documented `docker build --target runtime-prebuilt ...`.
   
   ### What Did You Expect to See?
   
   The packaged source satisfies every `COPY` of the stage that the target 
builds.
   
   ### What Did You See Instead?
   
   The build aborts on the missing root `LICENSE` (deploy.sh) or on 
`rmqctl/go.mod` (the manual path's context).
   
   ### Evidence
   
   - `server/Dockerfile:17-20` (context note), `:31-40` (the stage's COPYs), 
`:81-84` (`COPY --from=rmqctl-build`), `deploy/deploy.sh` (`package_source`, 
`build_server`), `.claude/skills/deploy-rocketmq/SKILL.md` (the manual tar and 
build).
   - Executed against the real packaging: extracting the previous file list and 
running the stage's context reads fails with `COPY failed: ... stat LICENSE: 
file does not exist`; the corrected list builds through every COPY step 
(`Successfully built`); `bash -n deploy/deploy.sh` passes.
   
   ### Impact
   
   The one-command deployment cannot build the server image on a fresh host, 
and the manual path cannot either.
   
   ### Acceptance Criteria
   
   - Both packages ship every file the Dockerfile's context reads, and the 
manual path builds from the repository root.
   
   **Corresponding PR:** #5433
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to