Google Professional Cloud Developer exam dumps

Google Professional Cloud Developer practice question 342 of 481

Professional Cloud Developer. Professional level, Google Cloud. Free question with the correct answer and a full explanation.

Google Professional Cloud Developer Question 342

Single answerGoogle Cloud Platform

You want to deploy a Node.js application to Google Cloud without manually creating a Dockerfile or managing infrastructure. The application source code is stored in a GitHub repository. Which approach should you take to deploy the application efficiently?

  1. A

    Use Google Cloud Build to create a custom Docker image and deploy it to a Google Kubernetes Engine (GKE) cluster.

  2. B

    Use Cloud Run with the 'Deploy from source' option to build and deploy the application directly from the GitHub repository.

  3. C

    Manually create a Compute Engine instance, clone the repository, and run the application using Node.js.

  4. D

    Use App Engine Standard Environment, upload the source code, and specify the required runtime in the app.yaml file.

Show answer and explanation

Correct answer: B

Explanation

Cloud Run's 'Deploy from source' feature allows developers to deploy applications directly from source code stored in a GitHub repository. It abstracts the need to manually create Docker images or manage infrastructure, making it an efficient and developer-friendly choice for deploying applications quickly and reliably.

  • A. Incorrect.

    This option requires you to manually create a Docker image and manage the GKE cluster, which is not the most efficient way to deploy directly from source code.

  • B. Correct.

    This is the correct approach. Cloud Run can automatically build and deploy an application from a GitHub repository using the 'Deploy from source' feature, removing the need to manually manage Dockerfiles or infrastructure.

  • C. Incorrect.

    This approach involves manual infrastructure management and lacks the automation and scalability of Google Cloud's managed services, making it less efficient.

  • D. Incorrect.

    While App Engine Standard Environment supports deploying source code by specifying a runtime in the app.yaml file, it does not natively integrate with a GitHub repository for automated deployment. Additional steps like manual uploads would be required.

Timed practice exam

Take a Google Professional Cloud Developer practice test under exam conditions

60 questions in 120 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam