I've imported my firebase project as a terraform resource, but got this when ran terraform plan:
│ Error: Error when reading or editing FirebaseProject "projects/myproject": googleapi: Error 403: Your application has authenticated using end user credentials from the Google Cloud SDK or Google Cloud Shell which are not supported by the firebase.googleapis.com. We recommend configuring the billing/quota_project setting in gcloud or using a service account through the auth/impersonate_service_account setting. For more information about service accounts and how to use them in your application, see https://cloud.google.com/docs/authentication/. If you are getting this error with curl or similar tools, you may need to specify 'X-Goog-User-Project' HTTP header for quota and billing purposes. For more information regarding 'X-Goog-User-Project' header, please check https://cloud.google.com/apis/docs/system-parameters.
│ Details:
│ [
│ {
│ "@type": "type.googleapis.com/google.rpc.ErrorInfo",
│ "domain": "googleapis.com",
│ "metadata": {
│ "consumer": "projects/774686551450",
│ "service": "firebase.googleapis.com"
│ },
│ "reason": "SERVICE_DISABLED"
│ }
│ ]
│
│ with google_firebase_project.default,
│ on main.tf line 27, in resource "google_firebase_project" "default":
│ 27: resource "google_firebase_project" "default" {
If I set the GOOGLE_APPLICATION_CREDENTIALS env var to a service account of that project, it seems to work, but I'd like to avoid it as it is required to re-export that variable each time I'm changing environment.
I've authenticated to gcloud via my user, which is admin for all the relevant project.