Skip to content

All certifications

XK0-006 practice question on Containers, 2026-11-15

Archived question for 2026-11-15. Domain: Services and User Management. Objective 2.6: Containers. Original SecLern question, written for practice.

Which command runs an nginx container in the background and publishes host port 8080 to container port 80?

Show the explanation

-p takes host port first, then container port.

Each option

  • A. That reverses the ports and publishes host port 80. It would be right for an application listening on 8080.
  • B. --expose only documents a port and does not publish it. It would be right for a port declaration.
  • C (correct). Correct: -p takes host port first, then container port.
  • D. -P publishes all exposed ports to random host ports. It would be right when any port is fine.

What this question tests

It maps to XK0-006 objective 2.6, Containers: Containers Related ideas: podman, port publishing.

The published topics under this objective, so you can check what you have covered:

  • Images and containers
  • Container networks
  • Volumes and logs

More from the archive

Start a daily session

Several questions at a time, aimed at your gaps.