-
Notifications
You must be signed in to change notification settings - Fork 47
Closed
Description
Bug Description
When running Maglev via Docker, GET / returns 404 index.html not found
instead of the welcome page.
Root Cause
index.html and marketing/ are copied into the builder stage via COPY . ., but the runtime stage
(based on alpine:3.21) only explicitly copies the binary and
config.example.json. Static web assets are never transferred to the final
image.
Additionally, marketing/ was listed in .dockerignore which would have
prevented it from reaching the builder stage in a fresh build context.
Steps to Reproduce
- Clone the repo
cp config.docker.example.json config.docker.jsondocker compose upcurl http://localhost:4000/
Expected: Welcome page HTML (status 200)
Actual: index.html not found (status 404)
Proposed Fix
- Add
COPY --from=builder /build/index.html ./index.htmlto the runtime stage inDockerfile - Add
COPY --from=builder /build/marketing/ ./marketing/to the runtime stage inDockerfile - Remove
marketing/from.dockerignoreso it is available in the builder stage
I have a fix ready and will open a PR referencing this issue.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels