A municipal compost lab has a working image, but the container exits immediately because nothing declares the process the runtime should start. Which instruction family defines the default executable for the container?
Select an answer to reveal the explanation.
Short Explanation
An image without ENTRYPOINT or CMD is like a music box with no song loaded—the box exists, but nothing plays when you open it. Those two instructions tell the runtime what process to start; COPY and WORKDIR just arrange the furniture.
Full Explanation
A container image is only useful at runtime if the host knows which process to launch. ENTRYPOINT and CMD are the instruction family that declare that default executable (and optional default arguments). Without one of them—or an override at docker run / ACI / Container Apps start—the compost lab’s otherwise valid image can start and then exit immediately because nothing stays running.
WORKDIR only changes the current directory for subsequent build steps and for the eventual process; it never defines what binary runs. COPY stages files into the image filesystem but does not start a process when the container begins. EXPOSE records intended listening ports as metadata for humans and tooling; it does not open sockets or keep a process alive.
Exam caveat: ENTRYPOINT and CMD interact. Shell form versus exec form, and whether CMD supplies arguments to an ENTRYPOINT binary, change override behavior. AZ-204 scenarios often expect the fixed binary in ENTRYPOINT and overridable defaults in CMD.
Operational check: inspect the built image with docker inspect (or equivalent) and verify Config.Entrypoint and Config.Cmd are populated as intended. Start the container locally or in ACI and confirm the scanner or API process appears in the process list instead of an immediate ExitCode.