instance_service_account.go raw

   1  package credentials
   2  
   3  // InstanceServiceAccount returns credentials for Compute Instance Service Account.
   4  // That is, for SDK build with InstanceServiceAccount credentials and used on Compute Instance
   5  // created with yandex.cloud.compute.v1.CreateInstanceRequest.service_account_id, API calls
   6  // will be authenticated with this ServiceAccount ID.
   7  // You can override the default address of Metadata Service by setting env variable.
   8  // https://yandex.cloud/ru/docs/compute/operations/vm-control/vm-connect-sa#cli_1
   9  func InstanceServiceAccount() NonExchangeableCredentials {
  10  	return MetadataService()
  11  }
  12