Question 170 of 500
Deploying applicationsmediumMultiple ChoiceObjective-mapped

Quick Answer

The answer is that the Cloud Run API is not enabled in the project. This is the most likely cause because the error message "Cloud Run API not enabled" directly indicates that the Cloud Build pipeline cannot interact with the Cloud Run service, as the API must be explicitly activated for the project before any deployments can occur. Even though the Cloud Build service account holds the roles/run.admin role at the project level, IAM permissions are irrelevant if the underlying API is disabled—Cloud Run simply does not exist as a resource endpoint for that project. On the Google Professional Cloud Developer exam, this question tests your understanding of the prerequisite API enablement step, which is a common trap: candidates often focus on IAM roles while forgetting that APIs must be turned on first. A helpful memory tip is "APIs before roles"—always verify that the required Google Cloud API is enabled in the project before troubleshooting permissions, as no amount of role assignments can substitute for an inactive API.

PCD Deploying applications Practice Question

This PCD practice question tests your understanding of deploying applications. The scenario asks you to isolate a root cause — eliminate options that address a different problem before choosing. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.

Exhibit

ERROR: (gcloud.run.deploy) PERMISSION_DENIED: Permission 'run.services.create' denied on resource 'projects/my-project/locations/us-central1/services/my-service' (or the resource may not exist).

Refer to the exhibit. A Cloud Build pipeline that deploys a Cloud Run service fails with the above error. The Cloud Build service account has the roles/run.admin role at the project level. What is the most likely cause?

Clue words in this question

Noticing these words before you look at the options changes how you read each choice.

  • Clue: "most likely"

    Why it matters: Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

Question 1mediummultiple choice
Full question →

Exhibit

ERROR: (gcloud.run.deploy) PERMISSION_DENIED: Permission 'run.services.create' denied on resource 'projects/my-project/locations/us-central1/services/my-service' (or the resource may not exist).

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

The Cloud Run API is not enabled in the project.

Option C is correct because the error message indicates that Cloud Run is not available, which typically occurs when the Cloud Run API has not been enabled in the project. Without the API enabled, any attempt to deploy a Cloud Run service via Cloud Build will fail, regardless of the service account's IAM roles. Enabling the API is a prerequisite for using Cloud Run resources.

Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Answer analysis

Option-by-option breakdown

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

  • The service account used by Cloud Build does not have the Cloud Run Invoker role.

    Why it's wrong here

    Incorrect. The run.admin role includes permission to create services; the Invoker role is for invoking, not deploying.

  • The Cloud Run service was deleted manually before the pipeline ran.

    Why it's wrong here

    Incorrect. If the service didn't exist, the error would be about resource not found, not permission denied.

  • The Cloud Run API is not enabled in the project.

    Why this is correct

    Correct. The API must be enabled for any Cloud Run operations to succeed.

    Clue confirmation

    The clue word "most likely" in the question point toward this answer.

    Related concept

    Read the scenario before looking for a memorised answer.

  • The region specified in the deploy step does not have Cloud Run enabled.

    Why it's wrong here

    Incorrect. The error is about permission, not region availability; a region issue would give a different error.

Common exam traps

Common exam trap: answer the scenario, not the keyword

Cisco often tests the distinction between IAM permissions (roles) and API enablement, trapping candidates who assume that granting a role automatically enables the underlying service API.

Detailed technical explanation

How to think about this question

Under the hood, Cloud Build uses the Cloud Run Admin API (run.googleapis.com) to create or update services. If this API is not enabled, the deployment step receives an HTTP 403 or 404 error with a message like 'Cloud Run API has not been used in project X before or it is disabled'. This is a common oversight when setting up a new project, as enabling the API is a separate step from granting IAM roles. In real-world scenarios, this error can also occur if the API was recently disabled or if the project has a service usage quota enforcement policy.

KKey Concepts to Remember

  • Read the scenario before looking for a memorised answer.
  • Find the constraint that changes the correct option.
  • Eliminate answers that are true in general but not in this case.

TExam Day Tips

  • Watch for words such as best, first, most likely and least administrative effort.
  • Review why wrong options are wrong, not only why the correct option is correct.

Key takeaway

Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Real-world example

How this comes up in practice

A company's IT admin needs to give a contractor read-only access to production logs without sharing account credentials. Using role-based access control (RBAC) and temporary scoped permissions — not a permanent shared password — is the correct pattern. Questions like this test whether you can apply least-privilege access across cloud identity services.

What to study next

Got this wrong? Here's your next step.

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Related practice questions

Related PCD practice-question pages

Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.

Practice this exam

Start a free PCD practice session

Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.

FAQ

Questions learners often ask

What does this PCD question test?

Deploying applications — This question tests Deploying applications — Read the scenario before looking for a memorised answer..

What is the correct answer to this question?

The correct answer is: The Cloud Run API is not enabled in the project. — Option C is correct because the error message indicates that Cloud Run is not available, which typically occurs when the Cloud Run API has not been enabled in the project. Without the API enabled, any attempt to deploy a Cloud Run service via Cloud Build will fail, regardless of the service account's IAM roles. Enabling the API is a prerequisite for using Cloud Run resources.

What should I do if I get this PCD question wrong?

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Are there clue words in this question I should notice?

Yes — watch for: "most likely". Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

What is the key concept behind this question?

Read the scenario before looking for a memorised answer.

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Last reviewed: Jun 25, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

This PCD 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 PCD exam.