Bird
0
0

What will be the output of the command docker events --filter event=start --filter container=myapp when the container myapp starts?

medium📝 Command Output Q13 of 15
Docker - Logging and Monitoring
What will be the output of the command docker events --filter event=start --filter container=myapp when the container myapp starts?
AA real-time event line showing the container <code>myapp</code> started
BA list of all containers currently running
CAn error saying invalid filter syntax
DNo output until the container stops
Step-by-Step Solution
Solution:
  1. Step 1: Understand the filters used

    The command filters events to show only start events for the container named myapp.
  2. Step 2: Predict output when container starts

    When myapp starts, the command outputs a line describing this event in real-time.
  3. Final Answer:

    A real-time event line showing the container myapp started -> Option A
  4. Quick Check:

    Filtered events show matching container start events [OK]
Quick Trick: Filters show only matching events live [OK]
Common Mistakes:
  • Expecting a list of containers instead of events
  • Thinking filters cause errors
  • Assuming output only on container stop

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Docker Quizzes