Skip to content

Deploy fails due to "missing" default storage bucket #6162

@bergeoisie

Description

@bergeoisie

[REQUIRED] Environment info

firebase-tools: 12.4.4

Platform: Ubuntu

[REQUIRED] Test case

Not sure the best way to do this since it relates to the state of firebase/GCP project.

[REQUIRED] Steps to reproduce

Run firebase deploy

[REQUIRED] Expected behavior

Deploy succeeds.

[REQUIRED] Actual behavior

After attempting to upgrade our firebase-tools version from 11.18.0 to 12.4.4, our deploys fail with

[2023-07-13T05:49:06.671Z] Default storage bucket is undefined.


There was an issue deploying your functions. Verify that your project has a Google App Engine instance setup at https://console.cloud.google.com/appengine and try again. If this issue persists, please contact support.

Error: Your project is being set up. Please wait a minute before deploying again.
1

It appears that the call to obtain the default storage bucket was changed in between those versions in #5973

I ran the calls locally to see the difference in output (redacting our project details). The old call:

 curl -X GET \
    -H "Authorization: Bearer $(gcloud auth print-access-token)" \
    -H "x-goog-user-project: REDACTED" \
    "https://appengine.googleapis.com/v1/apps/REDACTED"

returns

{
  "name": "apps/REDACTED",
  "id": "REDACTED",
  "authDomain": "gmail.com",
  "locationId": "us-central",
  "codeBucket": "staging.REDACTED.appspot.com",
  "servingStatus": "SERVING",
  "defaultHostname": "REDACTED.uc.r.appspot.com",
  "defaultBucket": "REDACTED.appspot.com",
  "serviceAccount": "REDACTED@appspot.gserviceaccount.com",
  "gcrDomain": "us.gcr.io",
  "databaseType": "CLOUD_DATASTORE_COMPATIBILITY",
  "featureSettings": {
    "splitHealthChecks": true,
    "useContainerOptimizedOs": true
  }
}

versus the new call:

 curl -X GET \
    -H "Authorization: Bearer $(gcloud auth print-access-token)" \
    -H "x-goog-user-project: REDACTED" \
    "https://firebase.googleapis.com/v1beta1/projects/REDACTED"

which returns a much smaller blob

{
  "projectId": "REDACTED",
  "projectNumber": "1234567890",
  "displayName": "REDACTED",
  "name": "projects/REDACTED",
  "resources": {
    "hostingSite": "REDACTED"
  },
  "state": "ACTIVE",
  "etag": "1_c080f4ba-b2da-4369-8f5f-b3a731257079"
}

It seems like these APIs might not actually be equivalent?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions