Distroless builds - httpserver-java17-springboot-distroless - #456
Teodorandrei22 wants to merge 1 commit into
Conversation
13979c9 to
b285633
Compare
There was a problem hiding this comment.
馃煛 Changes recommended
The new distroless variant includes a few user-facing correctness issues (doc/test references and README output mismatch) and a small API behavior inconsistency that should be fixed before approval.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Adds a distroless runtime variant of the existing Java 17 Spring Boot HTTP server example, intended to simplify the runtime filesystem by using gcr.io/distroless/java17-debian13.
Changes:
- Introduces a new
httpserver-java17-springboot-distrolessexample with Dockerfile + Kraftfile setup. - Adds a README describing build/deploy steps and customization points for the distroless variant.
- Adds an end-to-end test for the new example.
File summaries
| File | Description |
|---|---|
| httpserver-java17-springboot-distroless/Dockerfile | Adds multi-stage build using Debian build stage and distroless Java 17 runtime stage. |
| httpserver-java17-springboot-distroless/Kraftfile | Defines Unikraft Cloud runtime/target/rootfs and the Java command to start the app. |
| httpserver-java17-springboot-distroless/README.md | Documents how to build, deploy, validate, and customize the distroless variant. |
| httpserver-java17-springboot-distroless/DemoApplication.java | Spring Boot controller exposing /hello. |
| httpserver-java17-springboot-distroless/test_httpserver-java17-springboot-distroless.py | E2E test that deploys the image and validates the /hello endpoint response. |
Review details
Suppressed comments (1)
httpserver-java17-springboot-distroless/test_httpserver-java17-springboot-distroless.py:7
- In the docstring's step list, the image name in the build command uses the non-distroless example name; this should match the distroless variant to avoid copy/paste mistakes.
1. ``unikraft build . --output <prefix>/httpserver-java17-springboot:<tag>``
2. ``unikraft run --metro <metro> -p 443:8080/tls+http -m 1G --image ...``
3. ``curl https://<instance-url>/hello`` and assert "Hello, World!".
- Files reviewed: 5/5 changed files
- Comments generated: 4
- Review effort level: Lite
馃挕 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
b285633 to
e3ee131
Compare
There was a problem hiding this comment.
馃煛 Changes recommended
The new Dockerfile invokes unzip without installing it, which is likely to break the example build in CI and for users.
Get a fresh assessment by requesting another Copilot review.
Review details
- Files reviewed: 5/5 changed files
- Comments generated: 1
- Review effort level: Lite
Add distroless variant of httpserver-java17-springboot example. Use gcr.io/distroless/java17-debian13 as runtime base. Add Dockerfile, Kraftfile, README, and test file. Signed-off-by: Teodor Constantinescu <constantinescu.teodor22@gmail.com>
e3ee131 to
bda1165
Compare
There was a problem hiding this comment.
馃數 Needs a closer look
It introduces a new example with a distroless runtime base and runtime command assumptions that should be validated by a human via CI/runtime verification before approval.
Review details
- Files reviewed: 5/5 changed files
- Comments generated: 0 new
- Review effort level: Lite
-Add distroless variant of httpserver-java17-springboot example.
-Use gcr.io/distroless/java17-debian13 as runtime base.
-Add Dockerfile, Kraftfile, README, and test file.