Preparing Practice Exam…
Please wait a moment while the system generates the exam questions, answers, and study session.
Please wait a moment while the system generates the exam questions, answers, and study session.
Cisco Certified DevNet Associate (DEVASC) · Cisco
Select one answer.
Written by other learners. Comments can disagree with the marked answer — check the official documentation when in doubt.
I think C. The EXPOSE command makes the port available to other containers running on the same host (via Docker’s internal networking). This means that services running inside other containers on the same Docker network can communicate with this container on port 8080.
C is correct According to vendor documentation: "The EXPOSE instruction informs Docker that the container listens on the specified network ports at runtime. The EXPOSE instruction does not actually publish the port. It functions as a type of documentation between the person who builds the image and the person who runs the container, about which ports are intended to be published. To actually publish the port when running the container, use the -p flag on docker run to publish and map one or more ports, or the -P flag to publish all exposed ports and map them to high-order ports. Regardless of the EXPOSE settings, you can override them at runtime by using the -p flag." https://docs.docker.com/engine/reference/builder/