nerdexam
Google

ASSOCIATE-CLOUD-ENGINEER · Question #179

You built an application on your development laptop that uses Google Cloud services. Your application uses Application Default Credentials for authentication and works fine on your development…

The correct answer is A. Assign appropriate access for Google services to the service account used by the Compute. A does not state that it uses compute engine default service account, just say assigne IAM role to service account used by instance. When your application runs on an instance, Application Default Credentials can authenticate using the service account that has been enabled on…

Submitted by naveen.iyer· Mar 30, 2026Configuring access and security

Question

You built an application on your development laptop that uses Google Cloud services. Your application uses Application Default Credentials for authentication and works fine on your development laptop. You want to migrate this application to a Compute Engine virtual machine (VM) and set up authentication using Google-recommended practices and minimal changes. What should you do?

Options

  • AAssign appropriate access for Google services to the service account used by the Compute
  • BCreate a service account with appropriate access for Google services, and configure the
  • CStore credentials for service accounts with appropriate access for Google services in a config file,
  • DStore credentials for your user account with appropriate access for Google services in a config

How the community answered

(48 responses)
  • A
    75% (36)
  • B
    15% (7)
  • C
    2% (1)
  • D
    8% (4)

Explanation

A does not state that it uses compute engine default service account, just say assigne IAM role to service account used by instance. When your application runs on an instance, Application Default Credentials can authenticate using the service account that has been enabled on the instance. So important is, the service account is used by VM instance. https://cloud.google.com/compute/docs/access/create-enable-service-accounts-for- instances#clientlib

Topics

#Application Default Credentials#Compute Engine service account#ADC migration#authentication best practices

Community Discussion

No community discussion yet for this question.

Full ASSOCIATE-CLOUD-ENGINEER Practice