28 questions across 7 exams
You have just installed the Google Cloud SDK on your local machine. Which command should you run FIRST to authenticate and configure your default project?
You are working on multiple GCP projects. You want to switch your active gcloud configuration from 'project-a-config' to 'project-b-config'. Which command should you use?
You need to set the default compute zone to `us-central1-a` and the default project to `my-project-123` for your current gcloud environment. Which TWO commands should you use? (Select TWO)
You are writing a bash script that creates a Compute Engine instance. The script needs to run without user interaction and output ONLY the external IP address of the newly created instance in JSON format. How should you format the gcloud command?
You have just installed the Google Cloud SDK on your local machine. You want to authenticate, set your default project to 'my-company-prod', and set your default compute zone to 'us-central1-a' in a single interactive process. Which command should you run?
You are a developer working on two different GCP projects: 'project-dev' and 'project-prod'. You want to easily switch between these environments in your local Cloud SDK without having to re-authenticate or manually change the project ID every time. Which TWO gcloud commands are essential for setting up and switching between these environments? (Select TWO)
You are writing a bash script that will run on a CI/CD server. The script needs to deploy an application to App Engine. You want to ensure the script explicitly sets the target project to 'my-app-prod' for the deployment command, regardless of what the default gcloud configuration is set to on the server. Which command should you use?
You frequently create Compute Engine instances in the 'europe-west1-b' zone. You are tired of typing the '--zone=europe-west1-b' flag every time you run the 'gcloud compute instances create' command. Which command will set this zone as your default so you no longer have to specify it?
You have just installed the Google Cloud SDK on your local workstation. You need to authenticate with your Google account and set up your default project and compute region. Which single gcloud command should you run to begin this interactive setup process?
You are working in Cloud Shell and your current default project is set to 'dev-project-123'. You need to run several commands against resources in 'prod-project-999' without having to append the --project flag to every command. Which command should you use to change your default project for the current session?
You frequently switch between managing a 'Development' environment and a 'Production' environment. Each environment uses a different GCP project, a different default compute zone, and a different authorized service account. Which TWO gcloud commands should you use to efficiently manage and switch between these distinct environments without re-authenticating or resetting individual properties each time? (Select TWO)
You have installed the default Google Cloud SDK on your local machine. You now need to manage a Google Kubernetes Engine (GKE) cluster, but you realize the 'kubectl' command-line tool is not installed. Which command should you run to install kubectl using the Cloud SDK?
You have just installed the Google Cloud SDK on your local workstation. You need to authenticate, set your default project, and configure your default compute region and zone. Which single command will guide you through an interactive process to accomplish all of these tasks?
You are working in Cloud Shell and need to deploy resources to a project named 'finance-prod-2023'. Your current active configuration is pointing to 'dev-sandbox-123'. Which command should you use to change your default project for the current session without creating a new configuration?
You frequently switch between two different GCP environments: a personal project using your personal Gmail account, and a corporate project using your company email. You want to switch between these environments quickly without having to re-authenticate or manually change the project ID each time. Which TWO gcloud commands are essential to set up and use this workflow? (Select TWO)
You are trying to create a Cloud Storage bucket using the command line, but you cannot remember the exact syntax or flags required for the `gsutil mb` command. What is the FASTEST way to view the detailed documentation and examples for this specific command directly in your terminal?
You have just installed the Google Cloud SDK on your local workstation. You need to authenticate your user account, set up a default project, and configure a default compute zone. Which single command should you run to accomplish all of these tasks interactively?
You are working in Cloud Shell and need to execute several commands against a project named 'analytics-prod-992'. Your current default project is set to 'web-dev-123'. Which command should you use to change the default project for your current active configuration?
You frequently switch between two different Google Cloud projects: 'dev-env' and 'prod-env'. Each project requires you to use a different Google account for authentication and a different default compute zone. Which TWO actions should you take to switch between these environments with the LEAST amount of effort? (Select TWO)
You need to write a bash script that uploads local log files to a Google Cloud Storage bucket every night. Which command-line tool included in the Google Cloud SDK should you use?
You have just installed the Google Cloud SDK on your local workstation. You want to authenticate your account, set up a default project, and set a default compute region. Which single gcloud command will guide you through an interactive process to accomplish all of these tasks?
You work on two different Google Cloud projects: 'dev-project' and 'prod-project'. You frequently switch between them and need to use different accounts and default compute zones for each. What is the MOST efficient way to manage these different settings in the Cloud SDK?
You are working in the Cloud Shell and need to run several commands against a project with the ID 'my-company-analytics-123'. You want to avoid typing the project ID flag for every command. Which command should you run FIRST?
When you install the Google Cloud SDK using the default installation method, which three command-line tools are installed by default?
You have just installed the Google Cloud SDK on your local workstation. You need to authenticate your account, set up your default project, and configure your default compute zone. Which single command will guide you through an interactive process to accomplish all of these tasks?
You work on two different Google Cloud projects: 'dev-project' and 'prod-project'. You frequently switch between them in your local terminal and need to use different default compute zones and authentication accounts for each. What is the MOST efficient way to manage this in the Cloud SDK?
You are working in the Cloud Shell and want to deploy a Compute Engine instance. You realize your current active project is set to 'sandbox-123', but you need to deploy the instance in 'production-456'. Which command should you run to change your active project for the current session?
You are training a new team member on the Google Cloud SDK. You explain that a default installation of the Cloud SDK includes several command-line tools for interacting with different Google Cloud services. Which TWO of the following tools are included in the default Cloud SDK installation? (Select TWO)
Full answers, grading, and explanations on why each answer is correct.