Bird
0
0

In a CI pipeline, after running:

medium📝 Command Output Q5 of 15
Docker - in CI/CD
In a CI pipeline, after running:
docker login -u user -p password registry.example.com
docker push registry.example.com/myapp:2.0
What is the expected output if credentials are correct?
ADocker build is triggered automatically
BLogin fails due to wrong password
CLogin succeeds and image is pushed with progress shown
DImage push fails because login is not required
Step-by-Step Solution
Solution:
  1. Step 1: Understand docker login

    Login authenticates user to the registry using provided credentials.
  2. Step 2: Understand docker push after login

    If login succeeds, push uploads the image showing progress.
  3. Final Answer:

    Login succeeds and image is pushed with progress shown -> Option C
  4. Quick Check:

    Successful login + push = progress output [OK]
Quick Trick: Login before push to authenticate [OK]
Common Mistakes:
  • Skipping login causing push failure
  • Assuming push triggers build
  • Wrong password causing login failure

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Docker Quizzes