Open
Description
[REQUIRED] Environment info
firebase-tools: 14.6.0
Platform: macOS
[REQUIRED] Test case
I tried to deploy the Flutter docs to App Hosting, since they're open source: https://github.com/flutter/website. It's a lot of content.
[REQUIRED] Steps to reproduce
- Clone the Flutter docs (https://github.com/flutter/website)
pnpm install
- Add an
apphosting:build
script topackage.json
that's the same as thebuild-site-for-production
script - Add a
start
script topackage.json
:"start": "npx serve _static"
firebase init apphosting
firebase deploy --only apphosting
[REQUIRED] Expected behavior
An App Hosting rollout starts
[REQUIRED] Actual behavior
The deploy command fails with this error:
Error: Unable to parse JSON: SyntaxError: Unexpected token '<', "<?xml vers"... is not valid JSON
Looking at firebase-debug.log
, this error happens because the Storage upload returns this error, which the CLI doesn't know how to parse:
[2025-06-11T14:19:35.864Z] <<< [apiv2][status] PUT https://storage.googleapis.com/firebaseapphosting-sources-85476909309-us-central1/flutter-docs--34656-UsniywOpDMMZ-.zip 400
[2025-06-11T14:19:35.866Z] <<< [apiv2][body] PUT https://storage.googleapis.com/firebaseapphosting-sources-85476909309-us-central1/flutter-docs--34656-UsniywOpDMMZ-.zip "<?xml version='1.0' encoding='UTF-8'?><Error><Code>EntityTooLarge</Code><Message>Your proposed upload is larger than the maximum object size specified in your Policy Document.</Message><Details>Content-length exceeds upper bound on range</Details></Error>"
So the underlying error is from Cloud Storage:
Your proposed upload is larger than the maximum object size specified in your Policy Document