Bird
0
0

You want to deploy a new version of your app container image to Cloud Run and keep the same service URL. Which command should you use?

hard📝 Application Q15 of 15
GCP - Cloud Run
You want to deploy a new version of your app container image to Cloud Run and keep the same service URL. Which command should you use?
Agcloud container deploy myapp --image=gcr.io/myproj/app:v2
Bgcloud run create myapp --image=gcr.io/myproj/app:v2 --region=us-central1
Cgcloud run deploy --image=gcr.io/myproj/app:v2 --region=us-central1
Dgcloud run deploy myapp --image=gcr.io/myproj/app:v2 --region=us-central1
Step-by-Step Solution
Solution:
  1. Step 1: Understand updating a Cloud Run service

    To update an existing service and keep its URL, use 'gcloud run deploy' with the same service name.
  2. Step 2: Check options for correct update command

    gcloud run deploy myapp --image=gcr.io/myproj/app:v2 --region=us-central1 uses 'deploy' with service name and new image, which updates the service. Options A, B, and D are incorrect commands or missing service name.
  3. Final Answer:

    gcloud run deploy myapp --image=gcr.io/myproj/app:v2 --region=us-central1 -> Option D
  4. Quick Check:

    Deploy with same service name updates app [OK]
Quick Trick: Use 'deploy' with same service name to update [OK]
Common Mistakes:
  • Using 'create' instead of 'deploy' to update
  • Omitting service name
  • Using wrong gcloud commands

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More GCP Quizzes