← Quiz: Docker: all 10 questions
Quiz: Docker · Question 2 of 10
Why use a multi-stage Dockerfile for a Spring Boot app?
Why use a multi-stage Dockerfile for a Spring Boot app?
- A.Docker requires at least two stages
- B.The final image contains only the JRE and jar, not the JDK, Maven or source code
- C.It runs the tests twice
- D.It makes the jar file larger
Answer & explanation
Correct answer: The final image contains only the JRE and jar, not the JDK, Maven or source code
Smaller, faster to ship and with less attack surface.
Can you get the rest right without peeking?
Take the timed Quiz: Docker quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →