Bird
0
0

Given the following commands, what will be the output of gcloud run revisions list --service=my-app after deploying twice?

medium📝 Predict Output Q13 of 15
GCP - Cloud Run
Given the following commands, what will be the output of gcloud run revisions list --service=my-app after deploying twice?
gcloud run deploy my-app --image=image:v1 --no-traffic
gcloud run deploy my-app --image=image:v2 --no-traffic
AOne revision with image:v2
BNo revisions because traffic is zero
CTwo revisions: one with image:v1 and one with image:v2
DError because --no-traffic disables revisions
Step-by-Step Solution
Solution:
  1. Step 1: Understand deployment with --no-traffic

    Deploying with --no-traffic creates a new revision but does not route traffic to it.
  2. Step 2: Analyze multiple deployments

    Deploying twice with different images creates two separate revisions.
  3. Final Answer:

    Two revisions: one with image:v1 and one with image:v2 -> Option C
  4. Quick Check:

    Each deploy creates a revision even with no traffic [OK]
Quick Trick: Each deploy creates a revision, traffic doesn't affect revision count [OK]
Common Mistakes:
  • Assuming no traffic means no revision
  • Thinking only latest revision exists
  • Confusing traffic routing with revision creation

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More GCP Quizzes