0

I am trying to deploy a deep learning VM (via the marketplace) However I get an error - that there is no valid default service account available. I have tried the following options

  1. disabling & re-enabling the Compute Engine API.
  2. Enabling Dataproc API
  3. using gcloud auth login & gcloud auth activate-service-account options

However they are not working. Can someone point out whats my error. Thanks in advance!

Some links I have gone through:

Undeleting service account GCE Discussion-Restoring default service account StackOverflow- GCP service account not found

Aakash Gupta
  • 101
  • 1

1 Answers1

0

Have a look at this document first. Some Google managed accounts were automatically added to your project when it's created. You can find them at Cloud Console -> IAM & Admin-> IAM. There you should verify that they have the “Editor Role”. These accounts use the following format:

[PROJECT_NUMBER]-com...@developer.gserviceaccount.com
[PROJECT_NUMBER]@cloudservices.gserviceaccount.com

Also, at Cloud Console -> IAM & Admin -> Service accounts you should found

[PROJECT_NUMBER]-com...@developer.gserviceaccount.com

marked as “default service account”.

If you found no such accounts there, you can try add the them to your project in the IAM console. They must be assigned the “Editor” Role.

[PROJECT_NUMBER]-com...@developer.gserviceaccount.com
[PROJECT_NUMBER]@cloudservices.gserviceaccount.com

Then you must make sure that the Console (Cloud Console-> IAM & Admin-> Service Accounts) lists [PROJECT_NUMBER]-com...@developer.gserviceaccount.com as a "default service account".

You can always set the compute engine default account using Cloud SDK. The name the account uses should not matter, as long as it is set as default service account.

Serhii Rohoza
  • 1,354
  • 2
  • 4
  • 14
  • Thanks @Serhii Rohoza....but as I mentioned in my post, I have gone through these links, and the documentation on service account. Unfortunately that didn't help. `gcloud alpha compute project-info set-default-service-account` is an *alpha* function & not generally available. – Aakash Gupta Dec 17 '19 at 17:19
  • It's good however, that the GCP team has realized that losing a *default service account* happens quite frequently. And they are making a provision to easily create one! – Aakash Gupta Dec 17 '19 at 17:22
  • Could you update your first post to show which accounts do you have at the the moment and result of adding missed account to your project in the IAM console? – Serhii Rohoza Dec 18 '19 at 07:57