Courseiva
Manage and provision cloud infrastructuremediumMultiple ChoiceObjective-mapped

Google PCA Manage and provision cloud infrastructure Practice Question

A team uses Cloud Build to build container images and deploy to Cloud Run. They want to automate deployments whenever a new image is pushed to Container Registry. What is the best approach?

⚠ Common exam trap

The trap here is that candidates may overcomplicate the solution by choosing Cloud Functions or Cloud Scheduler, missing the fact that Cloud Build triggers natively integrate with Container Registry's Pub/Sub events for automated, event-driven deployments.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Configure a Cloud Build trigger that runs on a push to the container image in Container Registry

Cloud Build triggers can be configured to fire on a push to a container image in Container Registry, using the 'cloud-builds' Pub/Sub topic that Container Registry publishes to when an image is pushed. This allows Cloud Build to automatically run a build step (e.g., gcloud run deploy) to deploy the new image to Cloud Run without any polling or external infrastructure.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Use Cloud Deploy with a delivery pipeline that polls for new images

    Why it's wrong here

    Cloud Deploy does not have native image push trigger without Cloud Build.

  • Configure a Cloud Build trigger that runs on a push to the container image in Container Registry

    Why this is correct

    Cloud Build triggers can respond to image push events directly.

  • Create a Cloud Function that subscribes to Pub/Sub and calls Cloud Run deploy

    Why it's wrong here

    Possible but not the simplest; custom code needed.

  • Set up a Cloud Scheduler job to run a script that deploys the latest image

    Why it's wrong here

    Not event-driven; runs on schedule.

About these practice questions

One of 955 original PCA practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This PCA practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the PCA exam.