Medium1 markMultiple Choice

GCP ACE · Question 03 · Domain 1.1: Setting up cloud projects and accounts

You have just created a new Google Cloud project and want to deploy a containerized application using Google Kubernetes Engine (GKE). When you try to run the command to create the cluster, you receive an error stating that the API is not enabled.

Which gcloud command should you use to enable the necessary API?

Answer options:

A.

gcloud compute apis enable container.googleapis.com

B.

gcloud projects enable-api container.googleapis.com

C.

gcloud services enable container.googleapis.com

D.

gcloud api enable gke.googleapis.com

How to approach this question

Remember that APIs in Google Cloud are managed under the 'gcloud services' command group.

Full Answer

C.gcloud services enable container.googleapis.com✓ Correct
In Google Cloud, APIs are managed as services. The `gcloud services enable` command is used to enable specific APIs for a project. The API name for Google Kubernetes Engine is `container.googleapis.com`.

Common mistakes

Guessing `gcloud api enable` because it sounds logical, but the actual command group is `services`.

Practice the full GCP Associate Cloud Engineer Practice Exam 7

50 questions · hints · full answers · grading

More questions from this exam